[{"data":1,"prerenderedAt":585},["ShallowReactive",2],{"blog:/blog/migrate-from-ably-to-nolag":3},{"id":4,"title":5,"author":6,"body":7,"category":574,"date":575,"description":576,"excerpt":577,"extension":578,"meta":579,"navigation":170,"path":580,"readTime":581,"seo":582,"stem":583,"__hash__":584},"blog/blog/migrate-from-ably-to-nolag.md","Migrate from Ably to NoLag","Henco Burger",{"type":8,"value":9,"toc":564},"minimark",[10,14,19,22,42,46,125,129,310,314,485,489,503,507,514,518,530,534,560],[11,12,13],"p",{},"Ably is a mature realtime platform with rich delivery semantics. NoLag shares the same pub/sub foundation and presence model, so moving across is mostly a matter of renaming a few concepts. This guide maps Ably onto NoLag and shows the same flow in both.",[15,16,18],"h2",{"id":17},"why-teams-move","Why teams move",[11,20,21],{},"NoLag keeps the realtime transport you rely on and adds:",[23,24,25,33,39],"ul",{},[26,27,28,32],"li",{},[29,30,31],"strong",{},"Blueprint SDKs"," for chat, notifications, dashboards, tracking, and more.",[26,34,35,38],{},[29,36,37],{},"A coordination layer for AI agents",": dispatch, share state, observe, and approve, on the same platform as your app features.",[26,40,41],{},"One place for human-facing and agent-facing realtime.",[15,43,45],{"id":44},"concept-map","Concept map",[47,48,49,62],"table",{},[50,51,52],"thead",{},[53,54,55,59],"tr",{},[56,57,58],"th",{},"Ably",[56,60,61],{},"NoLag",[63,64,65,74,82,95,107,117],"tbody",{},[53,66,67,71],{},[68,69,70],"td",{},"API key / token auth",[68,72,73],{},"Actor access tokens",[53,75,76,79],{},[68,77,78],{},"Channel",[68,80,81],{},"Room + topic",[53,83,84,90],{},[68,85,86],{},[87,88,89],"code",{},"channel.subscribe('event', cb)",[68,91,92],{},[87,93,94],{},"room.on('topic', cb)",[53,96,97,102],{},[68,98,99],{},[87,100,101],{},"channel.publish('event', data)",[68,103,104],{},[87,105,106],{},"room.emit('topic', data)",[53,108,109,114],{},[68,110,111],{},[87,112,113],{},"channel.presence",[68,115,116],{},"Presence (per room)",[53,118,119,122],{},[68,120,121],{},"History",[68,123,124],{},"Message logging and replay",[15,126,128],{"id":127},"before-ably","Before: Ably",[130,131,136],"pre",{"className":132,"code":133,"language":134,"meta":135,"style":135},"language-js shiki shiki-themes github-light github-dark","import * as Ably from 'ably'\n\nconst ably = new Ably.Realtime('API_KEY')\nconst channel = ably.channels.get('chat')\n\nchannel.subscribe('message', (msg) => {\n  console.log('Received:', msg.data)\n})\n\nchannel.publish('message', { text: 'Hello!' })\n","js","",[87,137,138,165,172,203,226,231,261,278,284,289],{"__ignoreMap":135},[139,140,143,147,151,154,158,161],"span",{"class":141,"line":142},"line",1,[139,144,146],{"class":145},"szBVR","import",[139,148,150],{"class":149},"sj4cs"," *",[139,152,153],{"class":145}," as",[139,155,157],{"class":156},"sVt8B"," Ably ",[139,159,160],{"class":145},"from",[139,162,164],{"class":163},"sZZnC"," 'ably'\n",[139,166,168],{"class":141,"line":167},2,[139,169,171],{"emptyLinePlaceholder":170},true,"\n",[139,173,175,178,181,184,187,190,194,197,200],{"class":141,"line":174},3,[139,176,177],{"class":145},"const",[139,179,180],{"class":149}," ably",[139,182,183],{"class":145}," =",[139,185,186],{"class":145}," new",[139,188,189],{"class":156}," Ably.",[139,191,193],{"class":192},"sScJk","Realtime",[139,195,196],{"class":156},"(",[139,198,199],{"class":163},"'API_KEY'",[139,201,202],{"class":156},")\n",[139,204,206,208,211,213,216,219,221,224],{"class":141,"line":205},4,[139,207,177],{"class":145},[139,209,210],{"class":149}," channel",[139,212,183],{"class":145},[139,214,215],{"class":156}," ably.channels.",[139,217,218],{"class":192},"get",[139,220,196],{"class":156},[139,222,223],{"class":163},"'chat'",[139,225,202],{"class":156},[139,227,229],{"class":141,"line":228},5,[139,230,171],{"emptyLinePlaceholder":170},[139,232,234,237,240,242,245,248,252,255,258],{"class":141,"line":233},6,[139,235,236],{"class":156},"channel.",[139,238,239],{"class":192},"subscribe",[139,241,196],{"class":156},[139,243,244],{"class":163},"'message'",[139,246,247],{"class":156},", (",[139,249,251],{"class":250},"s4XuR","msg",[139,253,254],{"class":156},") ",[139,256,257],{"class":145},"=>",[139,259,260],{"class":156}," {\n",[139,262,264,267,270,272,275],{"class":141,"line":263},7,[139,265,266],{"class":156},"  console.",[139,268,269],{"class":192},"log",[139,271,196],{"class":156},[139,273,274],{"class":163},"'Received:'",[139,276,277],{"class":156},", msg.data)\n",[139,279,281],{"class":141,"line":280},8,[139,282,283],{"class":156},"})\n",[139,285,287],{"class":141,"line":286},9,[139,288,171],{"emptyLinePlaceholder":170},[139,290,292,294,297,299,301,304,307],{"class":141,"line":291},10,[139,293,236],{"class":156},[139,295,296],{"class":192},"publish",[139,298,196],{"class":156},[139,300,244],{"class":163},[139,302,303],{"class":156},", { text: ",[139,305,306],{"class":163},"'Hello!'",[139,308,309],{"class":156}," })\n",[15,311,313],{"id":312},"after-nolag","After: NoLag",[130,315,319],{"className":316,"code":317,"language":318,"meta":135,"style":135},"language-ts shiki shiki-themes github-light github-dark","import { NoLag } from '@nolag/js-sdk'\n\nconst client = NoLag('your_access_token')\nawait client.connect()\n\nconst room = client.setApp('chat').setRoom('general')\nroom.subscribe('message')\n\nroom.on('message', (data) => {\n  console.log('Received:', data)\n})\n\nroom.emit('message', { text: 'Hello!' })\n","ts",[87,320,321,333,337,356,370,374,405,418,422,444,457,462,467],{"__ignoreMap":135},[139,322,323,325,328,330],{"class":141,"line":142},[139,324,146],{"class":145},[139,326,327],{"class":156}," { NoLag } ",[139,329,160],{"class":145},[139,331,332],{"class":163}," '@nolag/js-sdk'\n",[139,334,335],{"class":141,"line":167},[139,336,171],{"emptyLinePlaceholder":170},[139,338,339,341,344,346,349,351,354],{"class":141,"line":174},[139,340,177],{"class":145},[139,342,343],{"class":149}," client",[139,345,183],{"class":145},[139,347,348],{"class":192}," NoLag",[139,350,196],{"class":156},[139,352,353],{"class":163},"'your_access_token'",[139,355,202],{"class":156},[139,357,358,361,364,367],{"class":141,"line":205},[139,359,360],{"class":145},"await",[139,362,363],{"class":156}," client.",[139,365,366],{"class":192},"connect",[139,368,369],{"class":156},"()\n",[139,371,372],{"class":141,"line":228},[139,373,171],{"emptyLinePlaceholder":170},[139,375,376,378,381,383,385,388,390,392,395,398,400,403],{"class":141,"line":233},[139,377,177],{"class":145},[139,379,380],{"class":149}," room",[139,382,183],{"class":145},[139,384,363],{"class":156},[139,386,387],{"class":192},"setApp",[139,389,196],{"class":156},[139,391,223],{"class":163},[139,393,394],{"class":156},").",[139,396,397],{"class":192},"setRoom",[139,399,196],{"class":156},[139,401,402],{"class":163},"'general'",[139,404,202],{"class":156},[139,406,407,410,412,414,416],{"class":141,"line":263},[139,408,409],{"class":156},"room.",[139,411,239],{"class":192},[139,413,196],{"class":156},[139,415,244],{"class":163},[139,417,202],{"class":156},[139,419,420],{"class":141,"line":280},[139,421,171],{"emptyLinePlaceholder":170},[139,423,424,426,429,431,433,435,438,440,442],{"class":141,"line":286},[139,425,409],{"class":156},[139,427,428],{"class":192},"on",[139,430,196],{"class":156},[139,432,244],{"class":163},[139,434,247],{"class":156},[139,436,437],{"class":250},"data",[139,439,254],{"class":156},[139,441,257],{"class":145},[139,443,260],{"class":156},[139,445,446,448,450,452,454],{"class":141,"line":291},[139,447,266],{"class":156},[139,449,269],{"class":192},[139,451,196],{"class":156},[139,453,274],{"class":163},[139,455,456],{"class":156},", data)\n",[139,458,460],{"class":141,"line":459},11,[139,461,283],{"class":156},[139,463,465],{"class":141,"line":464},12,[139,466,171],{"emptyLinePlaceholder":170},[139,468,470,472,475,477,479,481,483],{"class":141,"line":469},13,[139,471,409],{"class":156},[139,473,474],{"class":192},"emit",[139,476,196],{"class":156},[139,478,244],{"class":163},[139,480,303],{"class":156},[139,482,306],{"class":163},[139,484,309],{"class":156},[15,486,488],{"id":487},"presence-and-history","Presence and history",[11,490,491,492,497,498,502],{},"Ably presence maps to NoLag ",[493,494,496],"a",{"href":495},"/docs/concepts/presence","presence",", tracked per room with join and leave events and a live member list. If you use Ably history to fetch missed messages, NoLag covers that with ",[493,499,501],{"href":500},"/docs/concepts/qos","message logging and replay",", so a client that reconnects can catch up.",[15,504,506],{"id":505},"delivery-guarantees","Delivery guarantees",[11,508,509,510,513],{},"Ably is known for its delivery semantics. NoLag offers ",[493,511,512],{"href":500},"quality-of-service levels"," 0, 1, and 2 (at most once, at least once, exactly once) so you choose the guarantee per message rather than paying for the strongest everywhere.",[15,515,517],{"id":516},"authentication","Authentication",[11,519,520,521,524,525,529],{},"Ably authenticates with API keys and tokens, often carrying capabilities in the token itself. NoLag centres permissions on the ",[29,522,523],{},"actor",": every credential resolves to a typed actor (user, device, server, session), and its read and write access lives server-side as per-topic ACL rather than in each token. For browser clients, your backend mints a short-lived JWT (",[493,526,528],{"href":527},"/docs/client-tokens","client token",") signed with a project signing key, so long-lived credentials never leave your servers.",[15,531,533],{"id":532},"next-steps","Next steps",[23,535,536,544,552],{},[26,537,538,539,543],{},"Start with the ",[493,540,542],{"href":541},"/docs/getting-started","5-minute quick start",".",[26,545,546,547,551],{},"Read the deeper ",[493,548,550],{"href":549},"/compare/ably","NoLag vs Ably"," comparison.",[26,553,554,555,559],{},"Explore the ",[493,556,558],{"href":557},"/docs/high-level-sdks","high-level SDKs"," if you would rather not rebuild chat or dashboards by hand.",[561,562,563],"style",{},"html pre.shiki code .szBVR, html code.shiki .szBVR{--shiki-default:#D73A49;--shiki-dark:#F97583}html pre.shiki code .sj4cs, html code.shiki .sj4cs{--shiki-default:#005CC5;--shiki-dark:#79B8FF}html pre.shiki code .sVt8B, html code.shiki .sVt8B{--shiki-default:#24292E;--shiki-dark:#E1E4E8}html pre.shiki code .sZZnC, html code.shiki .sZZnC{--shiki-default:#032F62;--shiki-dark:#9ECBFF}html pre.shiki code .sScJk, html code.shiki .sScJk{--shiki-default:#6F42C1;--shiki-dark:#B392F0}html pre.shiki code .s4XuR, html code.shiki .s4XuR{--shiki-default:#E36209;--shiki-dark:#FFAB70}html .default .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}html.dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}",{"title":135,"searchDepth":167,"depth":167,"links":565},[566,567,568,569,570,571,572,573],{"id":17,"depth":167,"text":18},{"id":44,"depth":167,"text":45},{"id":127,"depth":167,"text":128},{"id":312,"depth":167,"text":313},{"id":487,"depth":167,"text":488},{"id":505,"depth":167,"text":506},{"id":516,"depth":167,"text":517},{"id":532,"depth":167,"text":533},"Migration Guide","2026-07-31","A practical guide to moving a realtime app from Ably to NoLag, with a concept map and before-and-after code for channels, publishing, presence, and history.",null,"md",{},"/blog/migrate-from-ably-to-nolag","6 min read",{"title":5,"description":576},"blog/migrate-from-ably-to-nolag","fMdsO2gmldXWSVk5eiIxPhcWl8h5QIDANfIiH6OYYfY",1788160341257]