The rapidly growing national debt in the U.S. since the 1970s has alarmed and intrigued the academic world. Consequently, the concept of dynamic (in)efficiency in an overlapping generations (OLG) world and the importance of the heterogeneous-agents and incomplete markets (HAIM) hypothesis to justify a high debt-to-GDP ratio have been extensively studied. Two important consensus emerge from this literature: (i) The optimal quantity of public debt is positive—due to insufficient private liquidity to support private saving and investment (see, e.g., Barro (1974), Woodford (1990), and Aiyagari and McGrattan (1998)); (ii) the optimal capital tax is positive—because of precautionary saving and the consequent failure of the modified golden rule (see, e.g., Aiyagari (1995)). But these two consensus views are seldom derived jointly in the same model, so the dynamic relationship between optimal debt and optimal taxation remains unclear in HAIM models, especially considering that the optimal quantity of debt must be judged by the golden-rule saving rate and any debt must be financed by future taxes. We use a primal Ramsey approach to analytically characterize optimal debt and tax policy in an OLG-HAIM model. We show that since precautionary saving and oversaving are not necessarily the same thing, they have different policy implications—the Ramsey planner opts to issue bonds to crowd out private savings if and only if a competitive equilibrium is dynamically inefficient regardless of precautionary savings. In other words, optimal debt can be negative even if households cannot insure themselves against idiosyncratic risk under borrowing constraints. The sign and magnitude of the optimal quantity of debt in turn dictate the sign and magnitude of optimal taxes as well as the priority order of tax tools such as a labor tax vs. a capital tax.