API: WebGL documentation status

This page tracks ongoing documentation work in the MDN WebGL API section. Feel free to contribute!


Pages Needs* tags Missing tags Editorial reviews Technical reviews Outdated pages Missing pages Dev-doc-needed bugs
306 2 (1%) 0 (0%) 11 (4%) 15 (5%) 17 (6%) 0 (0%) 0 (0%)

See also localization status of this section.

Needs* tags

Found 2 pages. Learn more about how to deal with meta-tags.

Editorial reviews

Found 11 pages. Learn more about how to do an editorial review.

Technical reviews

Found 15 pages. Learn more about how to do a technical review.

Outdated pages

Found 17 pages. These pages haven't been updated in over a year. Outdated pages can have problems with both content and format. Look at these pages and consider: Is this page talking about the Web of today? Does it look consistent with newer pages in this topic area? If not, make any needed changes.


Please help us to localize this documentation into different languages. Read more about how to translate.

Language Pages Translated Translations up to date
bn 293 1 (0%) 0 (0%)
de 293 16 (5%) 2 (12%)
es 293 11 (3%) 2 (18%)
fa 293 0 (0%) 0 (0%)
fr 293 68 (23%) 46 (67%)
it 293 1 (0%) 0 (0%)
ja 306 35 (11%) 5 (14%)
ko 293 22 (7%) 8 (36%)
pl 293 3 (1%) 0 (0%)
pt-BR 293 5 (1%) 0 (0%)
pt-PT 293 7 (2%) 3 (42%)
ru 293 19 (6%) 6 (31%)
zh-CN 293 107 (36%) 65 (60%)
zh-TW 293 6 (2%) 0 (0%)

Writing team



Tagging standard

  • Grouping tag is: "WebGL"


We will include what documentation we need to cover WebGL 2.0 functionality is implemented by Gecko, since some of that is expected to land in the next few months.

Other goals we wish to achieve:

  • Help new developers learn WebGL
  • Ease the transition for native OpenGL programmers to move to WebGL
  • Provide guidelines for porting desktop or mobile native apps to the Web using WebGL
  • Show how to use WebGL to accelerate 3D graphics
  • Demonstrate how to integrate WebGL with other content
  • Teach WebGL use without using external libraries
  • Offer a discussion of external libraries that can help make WebGL development easier


  • Documenting related technologies like asm.js and Emscripten are not in scope for this project, although they do need to be approached properly at some point. They'll be mentioned here, and possibly used to some extent in samples. But they're separate documentation projects.

User stories

  • I'm an experienced Web developer who wants to create a Web app using WebGL.
  • I'm a newcomer to Web development, but am an expert at C++ and have used OpenGL in the past; I just want to create a new Web app using WebGL.
  • I'm an experienced developer who wants to port a C/C++ application to the Web using WebGL.
  • I'm developing a Web site that needs some 3D elements and wonder if/how I can use WebGL for that.
  • I want to use WebGL for high-performance 2D graphics.

Documents needed

The lists here detail specific types of content that need to be produced, as well as precise pages that we know need to be produced or updated.

Types of pages

The following types of pages will need to be produced.

  • Reference [DONE!]
    • Interfaces
    • Properties
    • Methods
    • Events
    • Extensions
  • Landing pages [DONE!]
  • Guides/tutorials [DONE for overview of WebGL1 only]
  • Sample apps and web content [NOT DONE]

Developer guides needed

WebGL developer manual

This documentation covers every area of WebGL one at a time, detailing how they work and how they're used. This structure may or may not be complete, and may need to be cleaned up and reconfigured to make sense. It's not mandatory for the author to follow this exact content structure, as long as everything is covered.

Note: This likely needs a better title.

  • Introduction to WebGL
    • What it is and how it relates to OpenGL
    • Relationship to existing <canvas> API.
    • Benefits of WebGL
    • Availability
    • Overview of the documentation and what to expect
  • Working with contexts
    • Creating and destroying a context
      • Creating a context
      • Context attributes
      • Destroying a context
    • Configuring a context
      • Size
      • State (blending, color depth, etc)
      • Clipping and viewport
  • Buffers
    • The framebuffer and the frontbuffer
      • Covers these two buffers and how drawing into the framebuffer must be done in a single JavaScript callback, since it is automatically copied to the frontbuffer at appropriate times between JS calls
      • Explain how this differs from OpenGL
      • See https://hacks.mozilla.org/2013/04/the-concepts-of-webgl/
    • Creating and destroying buffers
    • Configuring buffers
  • Working with textures
    • Creating and destroying textures
    • Configuring textures
    • Generating texture content
  • Programs and shaders
    • Introduction and definitions
    • Introduction to GLSL
    • Creating and using shaders
      • Creating vertices
        • Assigning attributes to vertices
      • Building vertex arrays
      • Configuring uniforms
    • Creating and deleting programs
      • What they're for
      • Details about using programs
  • Using alternate framebuffers
    • Intro and use cases
    • Creating and binding framebuffers
    • Configuring framebuffers
    • Using renderbuffers for offscreen image data
      • Types of surfaces you need to render to that aren't used as textures to sample from
        • Depth buffers
        • Stencil buffers
        • (etc?)
      • Creating and using renderbuffers
    • See http://www.songho.ca/opengl/gl_fbo.html for extra information.
  • Drawing the rendered frame
    • How to let the browser blit to the frontbuffer
      • Using requestAnimationFrame()
      • Blit happens between JavaScript callbacks
    • Clearing the frame
    • Reading the back pixels
      • How to do it
      • Performance implications
  • Handling WebGL events
    • Handling loss and restoration of the rendering context
  • Integrating WebGL with other Web content
    • Overlaying WebGL using the alpha context attribute
    • Using WebGL alongside other content in a page
    • Using a video as a texture
    • Using a canvas as a texture
      • Drawing text in a 3D scene
      • Other concepts as appropriate
    • Using arbitrary Web content as a texture
  • Putting it all together
    • This chapter would take all the information above and present a complete WebGL demonstration, explaining briefly what's going on throughout, with links to the previous chapters for in-depth coverage.
  • WebGL extensions
  • Differences between WebGL 1.0 and WebGL 2.0
  • Differences between WebGL and OpenGL ES 3.0

WebGL stories

This documentation provides training through examples and solutions to specific use cases, instead of the topic-by-topic details from the WebGL developer manual.

  • Using WebGL for 2D graphics acceleration
    • Creating new projects using WebGL for 2D graphics
    • Updating existing Web games to use WebGL for better performance
  • Using WebGL for 3D graphics
    • Various examples; we need to come up with a good list, starting with something very bare-bones and simple and eventually covering all major topics.
  • Porting OpenGL software to WebGL (likely cross-references with Emscripten and asm.js documentation, as well as Game Center content).



The interfaces defined in the following specifications are tracked by this status page:

Specification Status Comment
WebGL 1.0 Recommendation Initial definition.
WebGL 2.0 Editor's Draft