Realtime Apps Made Simple

APIs for developers building secure realtime Mobile, Web, and IoT Applications

Simple APIs - Powerful Network
The world's first programmable network allows you to focus on shipping a great product instead of building and managing expensive infrastructure.
iOS (Obj-C)
iOS (Swift)
Android / Java
// send a message
    channel: 'chatChannel',
    message: { foo : 'bar' }
}, function ( status, response ) {
    console.log( status.error, response )
Dictionary<string, string> sendMessage = new Dictionary<string, string>();
sendMessage.Add("foo", "bar");
    message: sendMessage, 
    userCallback: DisplayPublishReturnMessage, 
    errorCallback: DisplayErrorMessage);
- (void)client:(PubNub *)client didReceiveStatus:(PNStatus *)status {
    if (status.operation == PNSubscribeOperation && status.category == PNConnectedCategory) {
        [self.client publish: @{@"foo": @"bar"} toChannel: @"chatChannel"
              withCompletion:^(PNPublishStatus *publishStatus) {
            if (!publishStatus.isError) {
            else {
                NSLog(@"Publish did fail with error: %@", 
                      status.errorData.data?: status.errorData.information);
func client(client: PubNub, didReceiveStatus status: PNStatus) {
    if status.operation == .SubscribeOperation && status.category == .PNConnectedCategory {
        client.publish(["foo": "bar"], toChannel: "chatChannel", 
                       withCompletion: { (publishStatus) in
            if !publishStatus.error {
            else {
                print("Publish did fail with error: \(status.errorData.data ?? status.errorData.information)")
Map message = new HashMap();
message.put("foo", "bar");

        .async(new PNCallback<PNPublishResult>() {
            public void onResponse(PNPublishResult result, PNStatus status) {
                if (status.isError()) {
                } else {
BLOCKS Executions
export default request => {
    request.message.hello = 'world!'
    return request.ok()
70+ Realtime SDKs
Choose from over 70 Realtime SDKs to easily connect your mobile, web, and IoT devices to the PubNub Data Stream Network.
. . . . . . . . . . . . . . . .

The Programmable Network

The PubNub Data Stream Network powers low-latency secure messaging on every device, at massive scale.

PubNub BLOCKS makes the network programmable, executing your application logic on data as it passes over the network, removing the need to deploy and scale app servers.

Powerful Features
Our easy to use APIs make developing realtime applications easy.
Publish Subscribe Messaging
Send and receive messages in under 0.25 seconds worldwide.
Online Presence Detection
Monitor users and devices in realtime to know who is online and offline.
Data Stream Storage
Store and retrieve messages for chat history, auditing, and more.
Mobile Push Notifications
Increase engagement with push notifications for iOS and Android.
Access Manager
Keep firm control over who has access to what data.
Scale Matters
Messages per Month
Unique Devices per Month
Point of Presence

Try PubNub Today

Connect up to 100 devices for Free