This paper provides the first systematic empirical examination of bureaucratic nepotism and anti-nepotism legislation using data for an entire modern bureaucracy. By linking confidential information on family ties and administrative employer-employee records for the universe of civil servants in Colombia, I uncover three sets of empirical findings. First, using a novel methodology of family network reconstruction, I provide evidence on the pervasiveness of close family connections in the public administration and demonstrate its negative relationship with the performance of public sector agencies. Second, by further exploiting within-bureaucrat variation in family connections generated by the turnover of top non-elected bureaucrats, I show that family connections to public sector managers and advisors distort the allocation and compensation of workers at lower levels of the hierarchy. Connected bureaucrats receive higher salaries and are more likely to be hierarchically promoted but are negatively selected in terms of public sector experience, education, and records of misconduct. Third, I evaluate an anti-nepotism legislation reform by exploiting a sharp discontinuity in the set of family connections restricted by this law. I prove the limited effectiveness of this reform and show how bureaucrats strategically responded to this policy change by substituting margins of favoritism and reshuffling posts within the public administration.