title: How to convert a file from ASCII to UTF-8?
body: <p>I'm trying to transcode a bunch a files from ASCII to UTF-8.</p>
  
  <p>For that, I tried using <code>iconv</code>:</p>
  
  <pre><code>iconv -f US-ASCII -t UTF-8 infile &gt; outfile
  </code></pre>
  
  <p><code>-f ENCODING</code>  the encoding of the input</p>
  
  <p><code>-t ENCODING</code>  the encoding of the output</p>
  
  <p>Still that file didn't convert to UTF-8. It is a .dat file. </p>
  
  <p>Before posting this, I searched Google and found information like:</p>
  
  <blockquote>
    <p>ASCII is a subset of UTF-8, so all ASCII files are already UTF-8 encoded. The bytes in the ASCII file and the bytes that would result from "encoding it to UTF-8" would be exactly the same bytes. There's no difference between them.</p>
  </blockquote>
  
  <p><a href="https://stackoverflow.com/questions/11303405/force-encode-from-us-ascii-to-utf-8-iconv">Force encode from US-ASCII to UTF-8 (iconv)</a></p>
  
  <p><a href="https://stackoverflow.com/questions/64860/best-way-to-convert-text-files-between-character-sets">Best way to convert text files between character sets?</a></p>
  
  <p>Still the above links didn't help.</p>
  
  <p>Even though it is in ASCII it will support UTF-8 as UTF-8 is a super set, the other party who is going to receive the files from me need file encoding as UTF-8. He just need file format as UTF-8.</p>
  
  <p>Any suggestions please.</p>