title: redirect subfolder to root with <subfolder-name>.html using htaccess
body: <p>I have website that has links like</p>
  
  <pre><code>domain-name.com/pages/contact-us/
  www.domain-name.com/pages/contact-us/
  domain-name.com/pages/about-us/
  www.domain-name.com/pages/about-us/
  and other pages ...
  </code></pre>
  
  <p>What I'm looking for how i can redirect them permanently to same subfoldername.html using htaccess . for example for all the links above should redirected to  </p>
  
  <pre><code>domain-name.com/contact-us.html
  www.domain-name.com/contact-us.html
  domain-name.com/about-us.html
  www.domain-name.com/about-us.html
  also for other pages, otherwise if page not found to root index.html .
  </code></pre>
  
  <p>Thanks in advance.</p>