Take the 2-minute tour ×

First of all, this is not a dupe of this question. You'll see why.

I'm working on a web application (not a mobile website; this will be JS-heavy), and the HTML we have so far (which was developed by someone else) uses the following doctype:


My question is: why not just use the standard HTML5 doctype?

<!DOCTYPE html>

What would be the differences between the two? The app we're developing is targeted towards smartphones (Android, iPhone, Windows Phone 7), but of course, we'd like to support as many platforms as possible (Symbian, BlackBerry, etc.).

What features / behaviors to the two doctypes enable / disable, and on what platforms?

What is the best doctype to use when developing a mobile web app? (and with this last question I will make this a community wiki)

Edit: How do I make this community wiki? :-/

share|improve this question
add comment

1 Answer

up vote 4 down vote accepted

XHTML Mobile Profile long predates HTML5. It is aimed primarily at lower-powered mobile devices such as mobile phones from the pre-smartphone generation, as part of the “WAP 2.0” stack.

If you want to continue to support this kind of device you should continue to use XHTML Mobile Profile or XHTML Basic, and ensure that your documents are well-formed XML and use only the features from those specs. If you only care about the new generation of mobile user-agents, that happily render normal [X]HTML[5] pages designed from standard desktop browsers, you can drop it and use whatever doctype you like.

share|improve this answer
Great answer, thanks –  Felix Nov 9 '10 at 12:26
add comment

Your Answer


