We test the agency theory of corporate political activity by examining the association between the legality of independent expenditures and antitakeover lawmaking in the US states. Exploiting changesinstate law regarding the use of corporate independent expenditures in the pre-Citizens United era, we estimate that a state is more likely to pass antitakeover statutes that entrench management when firms are allowed to make independent expenditures. We also find that this relationship is conditional on the competitiveness of a state's electoral environment, suggesting that the threat of independent expenditures may move vulnerable legislators' votes on less salient issues, such as corporate governance. These findings are robust to competing public interest and political economy explanations for anti-takeover lawmaking, and they reveal that allowing independent expenditures may create additional agency costs for owners through public policy. Finally, these results strongly challenge the claim that state-level antitakeover laws are exogenous to firms' activities.