Getting started with Spring Boot

To understand and to work with Spring Boot better, it is good to have a decent knowledge of Java, Spring framework and one of Maven/Gradle. Note that Spring Boot is just a convenient way to do Spring.


Starter POMs

There are various starter pom dependencies such as spring-boot-starter, spring-boot-starter-web and spring-boot-starter-jdbc etc., that will add all dependencies and provide even default configurations based on which starter pom we have selected. You can create a simple maven project and add the Spring boot starter parent and starter pom dependency to the build file.

For sample code and the dependencies for creating a simple web application, you can refer to the Quick Start section @ Note that the main method is the starting point to a Spring Boot application, even if it is a web application. method is responsible for starting spring, creating spring context, applying annotations and setting up container.

Also, even though not specified in the example, @SpringBootApplication annotation can be used for creating a Spring Boot application and wraps other commonly used annotations including @Configuration, @EnableAutoConfiguration and @ComponentScan.

You can go to the link and configure and create a simple Spring Boot project with all dependencies automatically added based on the options selected.

You can also use an IDE that provides Spring Boot support such as Spring STS or Intellij, which internally connects to With Intellij IDEA IDE, you can go to create new project and on the first page of the New Project wizard, select Spring Initializr in the left pane.

Spring Boot ships with a command line tool (Spring Boot CLI) that can be used if you want to quickly prototype with Spring. It allows you to run Groovy scripts, which means that you have a familiar Java-like syntax, without so much boilerplate code. You can install it by following: Spring Boot CLI also internally connects to

You can create a spring boot application MyABCAppln with a starter-web dependency as:

./spring init –dependencies=web MyABCAppln.


Spring Boot Samples

Spring also provides a set of sample Spring boot applications in their github repo. Find more @ Just clone and use them.

Search the Web

Custom Search

Searches whole web. Use the search in the right sidebar to search only within!!!