The irrational dispensing practices are responsible for antibiotic abuse and the spread of antibiotic resistance. Thus, the present study aims to evaluate the knowledge, attitudes, and practices of community pharmacists (CPs) regarding dispensing antibiotics without prescription (DAwP). A descriptive, cross-sectional study was conducted between March 1, 2023, and March 31, 2023, in community pharmacy settings of Lahore, Pakistan. A self-administered and pretested questionnaire was used for the data collection. Logistic regression analysis was used to determine the factors associated with the practices of community pharmacists. Data were analyzed using SPSS (version 26) and MS Office (2016). Among 359 respondents, many strongly agreed/agreed with the statements "DAwP is contributing to the development of antimicrobial resistance" (83%, n = 298) and "Antibiotic resistance has become a public health issue" (81.9%, n = 249). Overall, most of the community pharmacists claimed that the unwillingness of patients to visit physicians for non-serious infections (75.2%, n = 270) and good knowledge of pharmacists about the use of antibiotics (51%, n = 183) were the most common reasons attributable to dispensing of antibiotics without prescription. Cephalosporin (n = 260, 72.4%), penicillin (n = 254, 70.8%), and tetracyclines (n = 170, 47.4%) were the most commonly dispensed classes of antibiotics without prescription due to cold, flu and diarrhea. Most community pharmacists never/sometimes warn patients about the potential side effects of medicines (79.1%, n = 284). Logistic regression analysis revealed that community pharmacists 31-40 years of age (OR = 0.568, 95%CI = 0.348-0.927, p-value = 0.024) were significantly less associated with poor practices of dispensing antibiotics without prescription (DAwP) while those who were 'Managers' (OR = 4.222, 95%CI = 2.542-7.011, p-value = <0.001), had 3-5 years of experience (OR = 2.241, 95%CI = 1.183-4.243, p-value = 0.013), dispensed ≤25 antibiotics per day (OR = 12.375, 95%CI = 5.177-29.583, p-value = <0.001), were more likely to be associated with poor practices of dispensing of antibiotics without prescription. The community pharmacists had adequate knowledge, positive attitudes, and poor practices towards DAwP. Demographical factors such as age, job status, and work experience were the determinants of community pharmacists' practices towards dispensing antibiotics without prescription (DAwP). Hence, a multifaceted approach, including educational interventions, is needed to reduce the dispensing of antibiotics without prescription (DAwP).