Maximum Stable Memory Size for Motoko Canisters

Recently we got the good news that the Canister Stable Memory size has been increased to 96 Gigabytes (or 96 GiB):

However it seems this new limit would apply only to Rust Stable Structures. How about Motoko? How much space is available for a standard Motoko based Canister?

Previously for Motoko we had 4 Gigabytes, and only two were usable because we needed the upgrade methods to serialize and deserialize in the pre-upgrade / upgrade process. What is the limit now, half of 96 Gigabytes?

Thanks for any light on this subject.

2 Likes

You should be able to access the whole amount if you use the stable regions functionality that was recently added. You’ll likely always be restricted to some GB level if you use the stable var syntax because that data has to be streamed into and back out of stable memory upon upgrade and you eventually run out of cycles.

2 Likes