The PubNub Network makes Real-time easy with a Simple Communications API. Two Functions: Send/Receive (Publish/Subscribe). We provide a web-service API for businesses to build scalable Data Push communication apps on Mobile, Tablet and Web. Bidirectional JSON. @PubNub - IRC #pubnub @
JavaScript ActionScript Python Monkey Ruby Perl Other
Latest commit 6cac98e Mar 27, 2014 @geremyCohen geremyCohen Update
Failed to load latest commit information.
android adding redirect Feb 20, 2013
app-showcase moved examples to new JS Repo. Mar 1, 2013
arduino moving repo Mar 5, 2013
blackberry removing bb from main repo Feb 20, 2013
c-libevent migrating Apr 17, 2013
clojure Create LICENSE Jul 16, 2013
cocoa migrating cocoa Mar 1, 2013
coldfusion Create LICENSE Jul 16, 2013
construct2 Create LICENSE Jul 16, 2013
csharp-iis moving repo Mar 21, 2013
csharp moving repo Mar 21, 2013
erlang Create LICENSE Jul 16, 2013
flash moving flash Feb 27, 2013
games fixed multi-touch demo. Dec 18, 2013
google-app-engine/python updated Google App Engine python API with imporved JSON import provid… Nov 11, 2011
gwt removing gwt from main repo Feb 20, 2013
j2me removing j2me from main repo Feb 20, 2013
java removing java from main repo Feb 20, 2013
javascript-modern migrating Apr 17, 2013
javascript-webos migrating Apr 17, 2013
javascript moved javascript repository to new separate repository. Feb 24, 2013
lua-corona deleting lua-corona Oct 9, 2013
lua-moai moving moai Oct 9, 2013
monkey Create LICENSE Jul 16, 2013
mono-for-android moving repo Mar 21, 2013
mono-for-linux moving repo Mar 21, 2013
mono-for-mac moving repo Mar 21, 2013
monotouch moving repo Mar 21, 2013
nodejs migrating Apr 17, 2013
objective-c redirect readme Mar 1, 2013
opa Create LICENSE Jul 16, 2013
perl5 Create LICENSE Jul 16, 2013
perl6 Create LICENSE Jul 16, 2013
phonegap migrating Apr 17, 2013
php-rackspace new PHP client supports Rackspace Mar 21, 2013
php moving repo Mar 20, 2013
python-tornado moving to new repo Dec 6, 2013
python-twisted adding new RM Dec 6, 2013
python pointing to new repo Dec 6, 2013
qooxdo Create LICENSE Jul 16, 2013
ruby-rhomobile Create LICENSE Jul 16, 2013
ruby Update Mar 27, 2014
sencha migrating Apr 17, 2013
silverlight moving repo Mar 21, 2013
sinatra Create LICENSE Jul 16, 2013 migrating Apr 17, 2013
streams changed location of Stalker Code from streams dir to app-showcase dir. Oct 18, 2011
titanium migrating Apr 17, 2013
unity3d redirect May 15, 2013
websocket Update Mar 7, 2014
windows-phone-7 mv repo Mar 21, 2013
.gitignore added custom uuid feature Jan 15, 2013
.gitignore.orig merging CL-243 Nov 19, 2012
.project CL-108:Add Presence 3.2 to Android Aug 4, 2012
.pydevproject CL-108:Add Presence 3.2 to Android Aug 4, 2012 Update May 14, 2013
LICENSE Update LICENSE Mar 27, 2013 Update Mar 25, 2014 Update Dec 20, 2012

Connecting everyone on Earth in < 0.25s !

PubNub is a cross-platform client-to-client (1:1 and 1:many) push service in the cloud, capable of broadcasting real-time messages to millions of web and mobile clients simultaneously, in less than a quarter second!

Optimized for both web and mobile, our scalable, global network of redundant data centers provides lightning-fast, reliable message delivery. We're up to 100 messages/second faster than possible with WebSockets alone, and cross-platform compatibility across all phones, tablets, browsers, programming languages, and APIs is always guaranteed!

Support and Issues

Please email us at if you have any questions or issues with the client SDKs. Alternatively, you can open an issue in the Github repo of the client you have the concern about.

Supported Languages and Frameworks

The current list of supported languages and frameworks can be found on our github page.

Contact Us

Contact information for support, sales, and general purpose inquiries can found at

Demo and Webcast Links


Using Encryption with PubNub

For higher security applications, PubNub provides SSL and AES-based encryption features to help safeguard your data. Additional information and higher-level overviews of Cross-Platform AES Symmetric Key Encryption in general can be found in our blog post. A lower level diagram which details the PubNub encryption-communication flow can be found here.

HTTPS (SSL) 2048-bit Encryption

HTTPS is recommended for the highest level of security for REST requests to PubNub. Using REST over HTTPS is not required – however, for secure communication, you should make sure the client or REST toolkit you're using is configured to use SSL. The PubNub Cloud service will continue to support both HTTP and HTTPS.

AES Encryption

To enable AES encryption, instantiate a PubNub instance with the presence of the optional cipher_key attribute. The instance will use the value of the cipher_key attribute as the cipher key.

Message Signing with HMAC/SHA256

If the client is publishing, you must also include the secret_key attribute when instantiating the PubNub instance. If the client will only be subscribing, you do not need to include the secret_key attribute. The instance will use the value of the secret_key as the key to sign the message.

Secure Key Exchange

The exchange of the cipher key (and if the client is publishing, the secret key) must occur using a secure communication system, external to PubNub, in order to maintain secrecy of the keys.

For an example of using encryption with the PubNub JavaScript API, check out the PubNub Javascript Cryptography Demo page. The demo shows usage of the Cipher Key + SSL at the same time. There is not exchange however with a central authority server, which is a recommended step for distributing security keys. This example diagram with illustrate the recommended Central Authority Server model for proper Security Key Exchange.

REST API Considerations

In addition to platform-specific APIs, PubNub also supports a REST API.

Mandatory Headers

When using the REST API, it is mandatory to pass the following HTTP headers to the PubNub server for each request:

V: Version-Number
Accept: */*

Example Headers

V: 3.1
User-Agent: PHP
Accept: */*

Selecting a User-agent

Use one of the following User-Agents, based on your client platform, when making a REST-based request: *PHP, JavaScript, Node.JS, Ruby, Ruby-Rhomobile, Python, Python-Twisted, Python-Tornado, C-LibEV, C-LibEvent, C-Qt, VB, C#, Java, Java-Android, Erlang, Titanium, Corona, C-Arduino, C-Unity, C#-Mono, Lua, Obj-C-iOS, C#-WP7, Cocoa, Perl5