title: Best practice to have a RestController and a Controller in Spring Application
body: <p>I am not asking if it is <em>possible</em>, I know it is but I would like to know what's the best way to offer a rest service while having a front end in my application.</p>
  
  <p>I'm developing a Spring Boot application, I currently have a controller that calls jsp pages, and a <strong>separate</strong> RestController. I want to be able to consume it with an Android application.</p>
  
  <p>So is it correct to have both a Controller and a <strong>separate</strong> Restcontroller in my application? For example the Rest controller methods will be called from /api/*. </p>
  
  <hr>
  
  <p>Edit :
  I know the difference between the two, but since I want to be able to return a view ( and I shouldn't do that with a RestController) and I want to have a rest service I am wondering if I can have both of them (separately of course).</p>
  
  <p>Thank you so much in advance.</p>