---
title: "HTML5在Android IOS等移动平台上的兼容性"
author: "mmdev"
date: "2011-12-15T13:30:00Z"
tags: []
slug: "html5-android-ios"
draft: false
lastmod: "2012-10-29T21:18:05Z"
id: 1707985
url: "https://mmdev.iteye.com/blog/1707985"
---

最近尝试将做的一个Android项目web化，而其中的一个方案，就是做成html5的。于是做了一些Demo，也做了一些简单的研究。其中一个比较重要的问题，就是HTML5在Android和IOS的兼容性如何。

找到下面的表格，很好的解答了我的问题。

与看到这篇博文的好友一起分享。

Feature Safari on iOS Android Browser BlackBerry Browser Nokia Browser Internet Explorer Opera Firefox webOS Browser Version tested iPhone, iPad Phones  
(1-2.3, 4.0) Tablets (3.0+) Phones Tablet Meego - Nokia N9 Symbian Windows Phone Mobile Mini Android Minimum version tested 3.2 1.5 3.0 5.0 1.0 1.2 ^3 9 11 5 6 1.4

## Application Cache

### [W3C API](http://dev.w3.org/html5/spec/Overview.html)

Offline package installation.

![true](http://mobilehtml5.org/img/check.png) ![true](http://mobilehtml5.org/img/check.png)  
2.1+ ![true](http://mobilehtml5.org/img/check.png) ![true](http://mobilehtml5.org/img/check.png)  
6.0+ ![true](http://mobilehtml5.org/img/check.png) ![true](http://mobilehtml5.org/img/check.png) ![true](http://mobilehtml5.org/img/check.png) ![true](http://mobilehtml5.org/img/check.png) ![true](http://mobilehtml5.org/img/check.png)

## Web storage

### [W3C API](http://dev.w3.org/html5/webstorage/)

Persistent and session storage.

![true](http://mobilehtml5.org/img/check.png) ![true](http://mobilehtml5.org/img/check.png)  
2.0+ ![true](http://mobilehtml5.org/img/check.png) ![true](http://mobilehtml5.org/img/check.png)  
6.0+ ![true](http://mobilehtml5.org/img/check.png) ![true](http://mobilehtml5.org/img/check.png) ![true](http://mobilehtml5.org/img/check.png) ![true](http://mobilehtml5.org/img/check.png) ![true](http://mobilehtml5.org/img/check.png) ![true](http://mobilehtml5.org/img/check.png)

## Web SQL storage

### [W3C API (no active)](http://www.w3.org/TR/webdatabase/)

Persistent SQLite storage.

![true](http://mobilehtml5.org/img/check.png) ![true](http://mobilehtml5.org/img/check.png)  
2.0+ ![true](http://mobilehtml5.org/img/check.png) ![true](http://mobilehtml5.org/img/check.png)  
6.0+ ![true](http://mobilehtml5.org/img/check.png) ![true](http://mobilehtml5.org/img/check.png) ![true](http://mobilehtml5.org/img/check.png) ![true](http://mobilehtml5.org/img/check.png)

## Geolocation

### [W3C API](http://dev.w3.org/geo/api/spec-source.html)

Geolocation & tracking using GPS, cells or Wi-Fi.

![true](http://mobilehtml5.org/img/check.png) ![true](http://mobilehtml5.org/img/check.png)  
2.0+ ![true](http://mobilehtml5.org/img/check.png) ![true](http://mobilehtml5.org/img/check.png)  
6.0+ ![true](http://mobilehtml5.org/img/check.png) ![true](http://mobilehtml5.org/img/check.png) ![true](http://mobilehtml5.org/img/check.png) ![true](http://mobilehtml5.org/img/check.png) ![true](http://mobilehtml5.org/img/check.png) ![true](http://mobilehtml5.org/img/check.png)

## Multimedia

### [W3C API](http://dev.w3.org/html5/spec/Overview.html)

Video & Audio Players

![true](http://mobilehtml5.org/img/check.png) ![true](http://mobilehtml5.org/img/check.png)  
2.3+ ![true](http://mobilehtml5.org/img/check.png) ![true](http://mobilehtml5.org/img/check.png)  
7.0+ ![true](http://mobilehtml5.org/img/check.png) ![true](http://mobilehtml5.org/img/check.png) ![true](http://mobilehtml5.org/img/check.png) ![true](http://mobilehtml5.org/img/check.png) ![true](http://mobilehtml5.org/img/check.png) ![true](http://mobilehtml5.org/img/check.png)

## Server-Sent Events

### [W3C API](http://dev.w3.org/html5/eventsource/)

EventSource pattern to mantain the connection to the server open

![true](http://mobilehtml5.org/img/check.png)  
4.1+ ![true](http://mobilehtml5.org/img/check.png) ![true](http://mobilehtml5.org/img/check.png) ![true](http://mobilehtml5.org/img/check.png)

## Web Sockets

### [W3C API](http://dev.w3.org/html5/websockets/)

Newbidireccional protocol over HTTP

![true](http://mobilehtml5.org/img/check.png)  
4.2+ ![true](http://mobilehtml5.org/img/check.png)  
6.1+ ![true](http://mobilehtml5.org/img/check.png) ![true](http://mobilehtml5.org/img/check.png) ![true](http://mobilehtml5.org/img/check.png)  
7+ Feature Safari on iOS Android Browser BlackBerry Browser Nokia Browser Internet Explorer Opera Firefox webOS Browser Version tested iPhone, iPad Phones (1.0-2.3) Tablets (3.0+) Phones Tablet Meego - Nokia N9 Symbian Windows Phone Mobile Mini Android

## Web Workers

### [W3C API](http://dev.w3.org/html5/workers/)

Threading and background process communications

![true](http://mobilehtml5.org/img/check.png)  
5.0+ ![true](http://mobilehtml5.org/img/check.png)  
6.0+ ![true](http://mobilehtml5.org/img/check.png) ![true](http://mobilehtml5.org/img/check.png) ![true](http://mobilehtml5.org/img/check.png) ![true](http://mobilehtml5.org/img/check.png)

## Canvas API

### [W3C API](http://dev.w3.org/html5/spec/Overview.html)

2D Drawing API

![true](http://mobilehtml5.org/img/check.png) ![true](http://mobilehtml5.org/img/check.png) ![true](http://mobilehtml5.org/img/check.png) ![true](http://mobilehtml5.org/img/check.png) ![true](http://mobilehtml5.org/img/check.png) ![true](http://mobilehtml5.org/img/check.png) ![true](http://mobilehtml5.org/img/check.png)  
Anna+ ![true](http://mobilehtml5.org/img/check.png) ![true](http://mobilehtml5.org/img/check.png) ![true](http://mobilehtml5.org/img/check.png) ![true](http://mobilehtml5.org/img/check.png) ![true](http://mobilehtml5.org/img/check.png)

## SVG

### [W3C Working Group](http://www.w3.org/Graphics/SVG/)

Scalable Vector Graphics

![true](http://mobilehtml5.org/img/check.png) ![true](http://mobilehtml5.org/img/check.png)  
4.0+ ![true](http://mobilehtml5.org/img/check.png) ![true](http://mobilehtml5.org/img/check.png) ![true](http://mobilehtml5.org/img/check.png) ![true](http://mobilehtml5.org/img/check.png) ![true](http://mobilehtml5.org/img/check.png) ![true](http://mobilehtml5.org/img/check.png) ![true](http://mobilehtml5.org/img/check.png) ![true](http://mobilehtml5.org/img/check.png) ![true](http://mobilehtml5.org/img/check.png)

## Motion Sensors

### [W3C Standard](http://dev.w3.org/geo/api/spec-source-orientation.html)

Accelerometer, Gyroscope, Magnetometer

![true](http://mobilehtml5.org/img/check.png)  
4.2 ![true](http://mobilehtml5.org/img/check.png)  
4.0+ ![true](http://mobilehtml5.org/img/check.png) ![true](http://mobilehtml5.org/img/check.png) ![true](http://mobilehtml5.org/img/check.png)  
moz (custom)

## HTML5 Form Virtual Keyboards

### [W3C Standard](http://dev.w3.org/html5/spec/Overview.html)

Text Inputs with different keyboards

![true](http://mobilehtml5.org/img/check.png) ![true](http://mobilehtml5.org/img/check.png) ![true](http://mobilehtml5.org/img/check.png) ![true](http://mobilehtml5.org/img/check.png) ![true](http://mobilehtml5.org/img/check.png)  
Anna+ ![true](http://mobilehtml5.org/img/check.png) ![true](http://mobilehtml5.org/img/check.png) ![true](http://mobilehtml5.org/img/check.png)

## HTML5 Form New Controls

### [W3C API](http://dev.w3.org/html5/spec/Overview.html)

At least: Date, Time, Month, Range

![true](http://mobilehtml5.org/img/check.png)  
5.0+ ![true](http://mobilehtml5.org/img/check.png) ![true](http://mobilehtml5.org/img/check.png) ![true](http://mobilehtml5.org/img/check.png)

## Touch Events

### [W3C API](https://dvcs.w3.org/hg/webevents/raw-file/tip/touchevents.html)

touchstart, touchend, touchmove, touchcancel

![true](http://mobilehtml5.org/img/check.png) ![true](http://mobilehtml5.org/img/check.png)  
2.1+ ![true](http://mobilehtml5.org/img/check.png) ![true](http://mobilehtml5.org/img/check.png)  
6.1+ ![true](http://mobilehtml5.org/img/check.png) ![true](http://mobilehtml5.org/img/check.png) ![true](http://mobilehtml5.org/img/check.png)  
(android) ![true](http://mobilehtml5.org/img/check.png) Feature Safari on iOS Android Browser BlackBerry Browser Nokia Browser Internet Explorer Opera Firefox webOS Browser Version tested iPhone, iPad Phones (1.0-2.3) Tablets (3.0+) Phones Tablet Meego - Nokia N9 Symbian Windows Phone Mobile Mini Android

## CSS 3 Basic

### [W3C Standard](http://www.w3.org/TR/CSS/#css3)

opacity, backgrounds, text effects, rounded corners

![true](http://mobilehtml5.org/img/check.png) ![true](http://mobilehtml5.org/img/check.png) ![true](http://mobilehtml5.org/img/check.png) ![true](http://mobilehtml5.org/img/check.png)  
6.0 ![true](http://mobilehtml5.org/img/check.png) ![true](http://mobilehtml5.org/img/check.png) ![true](http://mobilehtml5.org/img/check.png)  
Anna+ ![true](http://mobilehtml5.org/img/check.png) ![true](http://mobilehtml5.org/img/check.png) ![true](http://mobilehtml5.org/img/check.png)  
partial ![true](http://mobilehtml5.org/img/check.png) ![true](http://mobilehtml5.org/img/check.png)

## CSS 3 Transforms 2D

### [W3C Standard](http://www.w3.org/TR/css3-2d-transforms/)

rotate, translate, scale, skew, matrix

![true](http://mobilehtml5.org/img/check.png) ![true](http://mobilehtml5.org/img/check.png)  
2.0+ ![true](http://mobilehtml5.org/img/check.png) ![true](http://mobilehtml5.org/img/check.png)  
6.0 ![true](http://mobilehtml5.org/img/check.png) ![true](http://mobilehtml5.org/img/check.png) ![true](http://mobilehtml5.org/img/check.png)  
Anna+ ![true](http://mobilehtml5.org/img/check.png) ![true](http://mobilehtml5.org/img/check.png) ![true](http://mobilehtml5.org/img/check.png)  
partial ![true](http://mobilehtml5.org/img/check.png) ![true](http://mobilehtml5.org/img/check.png)

## CSS 3 Transforms 3D

### [W3C Standard](http://dev.w3.org/csswg/css3-3d-transforms/)

scale3d, translate3d. Perspective, Backface

![true](http://mobilehtml5.org/img/check.png) ![true](http://mobilehtml5.org/img/check.png)  
4.0+ ![true](http://mobilehtml5.org/img/check.png) ![true](http://mobilehtml5.org/img/check.png) ![true](http://mobilehtml5.org/img/check.png)

## CSS 3 Transitions

### [W3C Standard](http://www.w3.org/TR/css3-transitions/)

Animations between two states

![true](http://mobilehtml5.org/img/check.png) ![true](http://mobilehtml5.org/img/check.png)  
2.0+ ![true](http://mobilehtml5.org/img/check.png) ![true](http://mobilehtml5.org/img/check.png)  
6.0 ![true](http://mobilehtml5.org/img/check.png) ![true](http://mobilehtml5.org/img/check.png) ![true](http://mobilehtml5.org/img/check.png)  
Anna+ ![true](http://mobilehtml5.org/img/check.png) ![true](http://mobilehtml5.org/img/check.png) ![true](http://mobilehtml5.org/img/check.png)

## CSS 3 Animations

### [W3C Standard](http://dev.w3.org/csswg/css3-animations/)

Animations with keyframes

![true](http://mobilehtml5.org/img/check.png) ![true](http://mobilehtml5.org/img/check.png)  
2.0+ ![true](http://mobilehtml5.org/img/check.png) ![true](http://mobilehtml5.org/img/check.png)  
6.0 ![true](http://mobilehtml5.org/img/check.png) ![true](http://mobilehtml5.org/img/check.png) ![true](http://mobilehtml5.org/img/check.png)  
Anna+ ![true](http://mobilehtml5.org/img/check.png) ![true](http://mobilehtml5.org/img/check.png)

## Viewport definition

### [W3C API](http://dev.w3.org/csswg/css-device-adapt/#viewport-meta-element)

Meta tag support.

![true](http://mobilehtml5.org/img/check.png) ![true](http://mobilehtml5.org/img/check.png)  
supports target-densityDpi ![true](http://mobilehtml5.org/img/check.png) ![true](http://mobilehtml5.org/img/check.png) ![true](http://mobilehtml5.org/img/check.png) ![true](http://mobilehtml5.org/img/check.png) ![true](http://mobilehtml5.org/img/check.png)  
Anna+ ![true](http://mobilehtml5.org/img/check.png) ![true](http://mobilehtml5.org/img/check.png)  
supports css & meta ![true](http://mobilehtml5.org/img/check.png) ![true](http://mobilehtml5.org/img/check.png)

## Position: fixed support

### [W3C Standard](http://www.w3.org/TR/CSS2/visuren.html#propdef-position)

Ability to mantain an element fixed in the viewport while scrolling / zooming

![true](http://mobilehtml5.org/img/check.png)  
5.0+ ![true](http://mobilehtml5.org/img/check.png)  
2.2+ & non scalable viewport ![true](http://mobilehtml5.org/img/check.png)  
3.1+ ![true](http://mobilehtml5.org/img/check.png)  
7.0+ ![true](http://mobilehtml5.org/img/check.png) ![true](http://mobilehtml5.org/img/check.png)

## Remote Debugger

Ability to attach a remote debugger, such as Web Inspector

![true](http://mobilehtml5.org/img/check.png)  
weinre (inspector) ![true](http://mobilehtml5.org/img/check.png)  
weinre (inspector) ![true](http://mobilehtml5.org/img/check.png)weinre (inspector) ![true](http://mobilehtml5.org/img/check.png)  
7.0+ ![true](http://mobilehtml5.org/img/check.png) ![true](http://mobilehtml5.org/img/check.png)  
DragonFly ![true](http://mobilehtml5.org/img/check.png)  
weinre (nspector) Feature Safari on iOS Android Browser BlackBerry Browser Nokia Browser Internet Explorer Opera Firefox webOS Browser Version tested iPhone, iPad Phones (1.0-2.3) Tablets (3.0+) Phones Tablet Meego - Nokia N9 Symbian Windows Phone Mobile Mini Android

## WebGL

### [Khronos Group API](http://www.khronos.org/webgl/)

3D Canvas for the web

![true](http://mobilehtml5.org/img/check.png)  
2.3 only on Sony Xperia ![true](http://mobilehtml5.org/img/check.png)  
2.0 beta ![true](http://mobilehtml5.org/img/check.png)

## XMLHttpRequest 2.0

### [W3C API](http://dev.w3.org/2006/webapi/XMLHttpRequest-2/)

AJAX 2.0: upload files, progress

![true](http://mobilehtml5.org/img/check.png)  
5.0+ ![true](http://mobilehtml5.org/img/check.png)  
4.0+ ![true](http://mobilehtml5.org/img/check.png) ![true](http://mobilehtml5.org/img/check.png)

## Navigation Timing API

### [W3C API](https://dvcs.w3.org/hg/webperf/raw-file/tip/specs/NavigationTiming/Overview.html)

Performance events for WPO

![true](http://mobilehtml5.org/img/check.png)  
4.0+ ![true](http://mobilehtml5.org/img/check.png)  
4.0+ ![true](http://mobilehtml5.org/img/check.png) ![true](http://mobilehtml5.org/img/check.png)  
7+

## Notifications API

### [W3C API](http://dev.w3.org/2006/webapi/WebNotifications/publish/)

Background alert notifications

![true](http://mobilehtml5.org/img/check.png)  
custom code

## Network Information API

### [W3C API](http://www.w3.org/TR/netinfo-api/)

Connection Type: 2G, 3G, 4G, WiFi

![true](http://mobilehtml5.org/img/check.png)  
2.2+ ![true](http://mobilehtml5.org/img/check.png)

## File API

### [W3C API](http://www.w3.org/TR/FileAPI/)

Opening local files through input type

![true](http://mobilehtml5.org/img/check.png)  
4.0+ ![true](http://mobilehtml5.org/img/check.png)

## CORS

### [W3C API](http://www.w3.org/TR/cors/)

Cross origin Resource Sharing, for cross domain AJAX request

![true](http://mobilehtml5.org/img/check.png) ![true](http://mobilehtml5.org/img/check.png)  
4.0+ ![true](http://mobilehtml5.org/img/check.png) ![true](http://mobilehtml5.org/img/check.png)

## HTML Media Capture

### [W3C API](http://www.w3.org/TR/html-media-capture/)

Taking pictures, record video and audio from an input file type

![true](http://mobilehtml5.org/img/check.png)  
4.0+ ![true](http://mobilehtml5.org/img/check.png)

## IndexedDB

### [W3C API](http://www.w3.org/TR/IndexedDB/)

Agnostic database system (replacement for Web SQL)

![true](http://mobilehtml5.org/img/check.png)