This library allows for the identification of a file's likely MIME content type. This is release 1.21 with new MIME types. The identification of MIME content type is based on a file's filename extensions. MIME types are used in MIME-compliant communications, as in e-mail or HTTP traffic, to indicate the type of content which is transmitted. MIME::Types provides the ability for detailed information about MIME entities (provided as a set of MIME::Type objects) to be determined and used programmatically. There are many types defined by RFCs and vendors, so the list is long but not complete; don't hesitate to ask to add additional information. This library follows the IANA collection of MIME types (see below for reference). MIME::Types for Ruby was originally based on and synchronized with MIME::Types for Perl by Mark Overmeer, copyright 2001 - 2009. As of version 1.15, the data format for the MIME::Type list has changed and the synchronization will no longer happen. MIME::Types is built to conform to the MIME types of RFCs 2045 and 2231. It follows the official {IANA registry}[] ({ftp}[]) with some unofficial types added from the the {LTSW collection}[].

installgem install mime-types -v 1.21

Austin Ziegler

45,328,780 total downloads 2,612,112 for this version


gem 'mime-types', '~> 1.21'
  1. 2.4.3 October 21, 2014 (116 KB)
  2. 2.4.2 October 15, 2014 (116 KB)
  3. 2.4.1 October 7, 2014 (115 KB)
  4. 2.3 May 23, 2014 (104 KB)
  5. 2.2 March 14, 2014 (98 KB)
Show all versions (23 total)