Background Obesity is a chronic disease with increasing prevalence. We aimed to explore primary care physicians' knowledge and attitudes about obesity and how knowledge and attitudes are associated with confidence and adherence to obesity guidelines and barriers to obesity treatment. Methods A questionnaire survey was sent by e-mail to 1642 primary care physicians in four regions in Sweden. The survey focused on the physicians' knowledge, attitudes towards obesity, confidence in obesity management, adherence to obesity guidelines and barriers to optimal care. We created different statistical indices for knowledge, attitudes and adherence. To analyse the correlation between these indices, we used linear regression analyses. Results Replies from 235 primary care physicians yielded a response rate of 14.3%. Most physicians answered correctly that obesity is a disease (91%), that obesity regulation sits in the hypothalamus (70%) and that obesity is due to disorders of appetite regulation (69%). However, 44% of the physicians thought that the most effective weight reduction method for severe obesity was lifestyle changes; 47% believed that obesity is due to lack of self-control, 14% mentioned lack of motivation and 22% stated laziness. Although 97% believed that physicians can help individuals with obesity and 56% suggested that obesity treatment should be prioritised, 87% of the physicians expressed that losing weight is the patients' responsibility. There was a positive association between higher knowledge and better adherence to obesity guidelines (B = 0.07, CI 0.02-0.12, p-value = 0.005) and feeling confident to suggest medication (p < 0.001) or bariatric surgery (p = 0.002). While 99% of the physicians felt confident to discuss lifestyle changes, 67% and 81% were confident to suggest medication or bariatric surgery, respectively. Respondents perceived that the greatest barrier in obesity management was lack of time (69%) and resources (49%). Conclusion There was a positive association between Swedish primary care physicians' knowledge and adherence to obesity guidelines and being more confident to suggest obesity treatment. Yet, many physicians had an ambivalent attitude towards obesity management.