title: What is the difference between a JWT token and a Refresh token?
body: <p>I'm trying to get my head around <code>refresh tokens</code> and how they work with <code>JWT</code>, so I can use it without <code>auth0</code> API service.</p>
  
  <ul>
  <li>Why refresh token format is different from JWT?</li>
  <li>refresh tokens are just simple tokens store in the db?</li>
  <li>How is the flow to use a refresh token to get a JWT token?</li>
  </ul>
  
  <p>Thanks!</p>
  
  <p><strong>UPDATE</strong></p>
  
  <p>As @Florent Morselli suggested. The fundamental question of this post is wrong and confusing. Since JWT and refresh tokens are not really concepts that can be related. A better question can be:</p>
  
  <ul>
  <li>What is the difference between a JWT Token and an opaque token?</li>
  <li>What is the difference between a Access Token and a Refresh Token?</li>
  </ul>
  
  <p>I'm not changing the question in the title, since somebody might be looking wrongly for the same thing and it will lead them to this post.</p>