OAuth 2.0 is a product of the Internet Engineering Task Force, formally documented in RFC 6749 and RFC 6750. Google’s implementation is described in Using OAuth 2.0 to Access Google APIs.
It’s easiest to understand OAuth 2 by starting with the notion of an “Access Token”, which is just a string of characters. It’s a “bearer token”, which means that you send it along with an HTTP request, either using the HTTP Authorization header (which is the best practice) or as an ?access_code= name/value pair tacked onto the end of a URI (which is not as secure).
The token represents the right for you to make that HTTP request to whatever the URI identifies. The tokens are fairly short-lived (an hour or less is typical) but can be refreshed, unless they’ve been revoked. Here's is an example of a token, a string which for an hour in December 2012 represented the right for the user of a particular Google Account to access the Google+ API: ya29.AHES6ZQRUz_7TzCdPehdeGeh6g4yFIBZGOwi-nRJTlg3XoQ
OAuth 2.0 also specifies how you go about getting a token; the inputs to this process include the identity of the user for whom access is being requested, and one or more scopes, strings which identify resources for which access is being sought. The process is a fairly involved HTTP dance involving several distinct servers, notably including:
One hosting the resource you’re trying to access,
one that can authenticate the person logged into the browser making the request, and
one that can issue and refresh the actual tokens.
The first redirects to the second redirects to the third and then you go back with your token to the first and do the actual work you started out trying to do. The control can flow entirely back and forth through the browser, with reasonably straightforward JavaScript, or through a back-channel between servers, which some regard as more secure.
The OAuth 2.0 specifications lay out how to build the target and redirect URIs, and encode the parameters. They also specify that any app using these protocols has to be registered with the server-side in advance.
The software offered by Google lets you conduct the OAuth flows directly, with direct access to the HTTP-level interchanges. However, in most cases, it's a better choice to use a high-level library such as Google+ Sign-in that encapsulates this at a level that is more convenient for the programmer, and probably less likely to introduce security vulnerabilities.
Note that Google offers a token revocation endpoint, so you can programmatically shut off previously-granted access. Also, end-users can do this interactively at the Authorized Access to your Google Account page. To reach this page, they should access the drop-down menu beside their picture at the right of the Google “sandbar” at the top of pages such as Gmail and Google+, select “Account”, from that page select “Security”, and from that page select “Connected applications and sites”.