Blog

Your dream job? Lets Git IT.
Interactive technical interview preparation platform designed for modern developers.

XGitHub

Platform

  • Categories

Resources

  • Blog
  • About the app
  • FAQ
  • Feedback

Legal

  • Privacy Policy
  • Terms of Service

© 2025 LetsGit.IT. All rights reserved.

LetsGit.IT/Categories/Spring
Springmedium

Bean scopes in Spring — what does `singleton` vs `prototype` mean?

Tags
#bean#scope#singleton#prototype
Back to categoryPractice quiz

Answer

`singleton` (default) means one bean instance per Spring container. `prototype` means a new instance each time the bean is requested; for web apps you also have request/session scopes.

Related questions

Spring
What do `@Configuration` and `@Bean` do in Spring?
#configuration#bean#spring-core
Spring
What are Bean Scopes?
#bean#scope#lifecycle
Spring
@Component vs @Bean?
#annotation#configuration#bean
Kotlin
Object declarations: what are they and when would you use them?
#kotlin#object#singleton