This paper studies the optimal tax-and-transfer policy when automation raises productivity but displaces unskilled workers. Using a general equilibrium model calibrated to the U.S. economy, we compute the steady-state social welfare-maximizing rate of each of four tax instruments: capital income taxation, unskilled wage taxation, taxation on automation capital (i.e., a robot tax), and consumption taxation. Following an increase in the productivity of automation-related capital, the welfare-maximizing capital income tax rate is small, and the welfare-maximizing robot tax rate is zero at the baseline labor-automation elasticity because their long-run investment distortions largely offset their redistributive social benefits. In the baseline simulation, aggregate welfare is maximized by lowering the unskilled wage tax rate and/or raising the consumption and capital income tax rates, whilst the social welfare improvement is always the largest for optimal consumption taxation. When unskilled labor and automation-related capital are highly substitutable, the optimal consumption tax rate increases, and the additional government revenue is redistributed to displaced unskilled workers.