This paper evaluates the association of maternal variables and of variables related to prenatal and delivery care with cesarean sections at a public and at a private maternity. A retrospective cross-sectional study was performed at a public maternity clinic (2,889 deliveries) and at a private maternity clinic (2,911 deliveries) in the city of Ribeirão Preto, São Paulo State, Brazil. The prevalence of cesarean sections was 18.9% at the public maternity clinic and 84.3% at the private one. The factors associated with cesarean sections at both hospitals were: mothers from other cities, aged > or =25 years and with hypertension. Having more than one child was a protective factor. At the public hospital, cesarean sections were more frequent on Wednesdays and from 12:00 to 23:59 hours of any day of the week, whereas at the private hospital they occurred on any day, though were less common on Sundays, and at any time except in the early morning. At the private hospital, cesarean sections were more frequent when performed by the doctor who had provided the prenatal care. Non-medical factors were more associated with cesarean sections in the private maternity clinic than biological or clinical factors related to pregnancy.