Take the 2-minute tour ×
Webmasters Stack Exchange is a question and answer site for pro webmasters. It's 100% free, no registration required.

I've been fine-tuning my font stacks lately and was wondering if it's safe to drop Courier from my monospace font stack yet? Would you feel comfortable dropping it?

Of course, monospace is my final fallback.

Note 1:

OS Testbed: WinXP, WinVista, Win7, iPhone, iPad

Based on my research, these browsers now substitute Courier New for Courier by default:

  • IE9+
  • Chrome 2+
  • Firefox 10+
  • Safari 3.1+
  • iDevices

Note 2:

The default "font-family: monospace;" renders as Courier New in every browser I've tested, from IE6 through the latest iPhone/iPad devices. EDIT: One exception is Opera 12, which renders Consolas on Win. Opera 10 renders Courier New.

Note 3:

I've noticed that Courier refuses to render with any font smoothing (anti-aliasing) in any browser I've tested, regardless of system and/or browser display settings. Probably because it's an old bitmap font. This could be because of my system setup, however.

share|improve this question

4 Answers 4

up vote 6 down vote accepted

It's safe to drop Courier...

Declaring "Courier New", monospace or just monospace should give you 100% monospace coverage on Windows, Mac, Linux, and mobile devices.

Courier New has been available since Windows 3.1, and all common OSes have monospace fonts available if Courier New isn't available. (Android has Droid Sans Mono, for example.)

...but that doesn't mean that you should

It's still worth considering Courier and even favouring it over Courier New in some situations, because Courier New is thinner and harder to read than Courier, especially on high-resolution screens and at smaller sizes.

Here's a screenshot of Courier New in Chrome on GitHub's site:

Courier New on GitHub

And here's the same section using Courier (which is what GitHub uses for Macs by default if you don't edit the CSS source for the purposes of demonstrating the differences):

Courier on GitHub

The differences are subtle, but Courier is heavier and more legible at 12px than Courier New, especially if you have a lot of text to trawl through.

Github's monospace font stack is Consolas, "Liberation Mono", Courier, monospace. Although it's aimed at programmers, it's more interesting than declaring monospace, because it takes advantage of newer typefaces on some systems.

Consolas is the newer monospace font that ships with Windows Vista and Windows 7 and with MS Office, and Liberation Mono is installed by default on many flavours of Linux and favoured by some programmers.

As ever, it comes down to specific applications over general rules, as Su' implied in her answer. Drop Courier from your stack only if there's a good reason to do so. If you're declaring Courier after "Courier New" as a fallback, then you probably don't need to do that anymore. But, as ever, test both options and see what works in each use case, as GitHub clearly have.

share|improve this answer
    
Of consideration for future readers, the screenshots above show anti-aliased versions of Courier. It looks much different to users with font smoothing disabled. –  Jeff Aug 22 '12 at 9:25
    
Surely there are better monospace fonts on Macs than Courier? –  DisgruntledGoat Aug 22 '12 at 9:28
    
@DisgruntledGoat Menlo is the default for Terminal and Xcode, but it's only bundled on OS 10.6 and higher (Snow Leopard). Monaco was the default before that. Whether or not they're 'better' than Courier is a matter of opinion, I suppose. They're certainly different. –  Nick Aug 22 '12 at 10:07

The question kind of implies it was ever not time; neither's really the case. Font stacks have always been entirely optional. Drop it if you want/feel it's appropriate.

If you think about it, your research is only actually of interest if you specifically did want old Courier(since it now seems to not want to display.)

share|improve this answer
    
I realize there's probably no "right" answer. It's more of a comfort-level thing for me at this point. I've been adding Courier to my monospace font stack for so long, I find myself adding it out of habit nowadays. Curious what others think. –  Jeff Aug 22 '12 at 1:15

As Nick says, keep Courier for Mac users. And for Linux users, don't forget Courier 10 Pitch, which isn't faint like Courier New. These are two ingredients of a Courier-like stack that suppresses Courier New.

If you prefer Liberation Mono to Courier, note that Google's Cousine is a Web Font identical to Liberation Mono.

share|improve this answer
    
Thank you for Courier 10 Pitch! I actually love the Courier feel for a part of my app but wasn't find something quite like the Mac's for Linux. –  Vic Goldfeld Apr 3 '13 at 11:28

Drop specific named fonts entirely from your CSS.

All modern browsers have user preferences for fonts (sans-serif, serif, fantasy, cursive and monospace). By default these are set to sensible values, for most browsers this comes to: <default>=sans-serif, sans-serif=Arial, serif=Times New Roman, monospace=Courier New, or similar font faces to those. So setting font-family: Arial, sans-serif; in your CSS is therefore pointless, as sans-serif most likely already aliases to Arial.

For accessibility reasons, you should respect these were possible. Aside from that, respecting user preferences is a great idea in general.

share|improve this answer
1  
In my opinion you should also never ever again use Courier and Courier New. I find these incredibly hard to read ;) –  fresch Sep 19 '12 at 7:08
    
Also, Helvetica usually maps to a (quite ugly, jagged, not antialiased) bitmap font on most Linux. Which is doubly sad, because these systems usually had DejaVu, Liberation or even the Microsoft common font packages installed ;) –  fresch Sep 19 '12 at 7:12
    
And to emphasize, you should drop (specific named fonts) where possible. Sometimes your designer is just absolutely adamant about a certain font-family. I've found arguing with designers to be a waste of time, in the end they usually got their way by stubbornness ;) –  fresch Sep 19 '12 at 7:16

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.