{"course":{"slug":"cloud-and-shipping","title":"Shipping It","url":"https://addaly.com/learn/cloud-and-shipping","level":"intermediate","track":"build"},"lesson":{"slug":"managed-or-self-hosted","title":"What to run yourself, and what to pay for","url":"https://addaly.com/learn/cloud-and-shipping/managed-or-self-hosted","position":67,"of":74,"minutes":9,"answer":"Compare money against hours of attention, not money against money: buy the stateful things whose backup, restore and upgrade obligations would eat your weekends, run the stateless ones that recover by restarting.","keyIdea":"Compare money against hours of attention, not money against money: buy the stateful things whose backup, restore and upgrade obligations would eat your weekends, run the stateless ones that recover by restarting, and check how you would leave before you join."},"body":{"format":"markdown","text":"## The comparison people make is the wrong one\n\nA managed Postgres costs perhaps $25 a month at small size. The same database on a VPS you already rent costs nothing extra. So self-hosting saves $300 a year, and people take that deal without writing down the other side of it.\n\nThe other side is a list, and it is the same list every time: installing and configuring it, taking backups, testing a restore, applying security patches, upgrading major versions, monitoring disk and connections, tuning when it slows down, and being the person who fixes it at 2am. Put an hour a month against that (which is optimistic) and at any realistic hourly value the managed service was cheaper before you finished reading this paragraph.\n\nThat is not an argument for buying everything. It is an argument for comparing the same two columns each time: **money** and **hours of your attention**, where attention is the scarcer one for a small team.\n\n## The three questions that decide it\n\n1. **Is this thing stateful?** Stateless services are easy to run yourself: if one dies, start another. Stateful ones (databases, queues with durable state, object storage, search indexes) carry backup, restore, replication and upgrade obligations that dominate the work. **Buy state, run stateless** is the single most useful heuristic here.\n2. **What happens at 3am if it breaks?** If the answer is \"I do not know how to fix it\", either learn before you depend on it, or pay somebody whose job that is.\n3. **Would running it teach you something you need?** A genuine reason. Running Postgres yourself for a year teaches you more about databases than any course. Do it on a side project, not on the thing with users.\n\n## What is usually worth paying for, at small scale\n\n- **The database.** Backups, point-in-time recovery, failover and version upgrades, for the price of two coffees a week. This is the best value on the list.\n- **Email delivery.** The deliverability lesson explained why running your own mail server is a losing fight.\n- **TLS certificates and DNS.** Free or nearly, and automated.\n- **Error tracking and uptime checks.** Free tiers are generous, and self-hosting your monitoring on the machine being monitored is a known trap.\n- **Object storage.** Durability you cannot easily reproduce.\n\n## What is usually fine to run yourself\n\n- **Your own application.** Obviously.\n- **A cache.** Redis or Valkey on the same box, treated as disposable, is low-maintenance because losing it is survivable by design.\n- **A reverse proxy.** Caddy or nginx. One config file, rarely touched.\n- **Batch jobs and workers.** Stateless, restartable, cheap.\n- **Small internal tools.** Metabase, a status page, a wiki.\n\n## The middle ground people forget\n\nBetween \"my own machine\" and \"a hyperscaler\" is a large and underrated space: a €5 to €20 VPS from Hetzner, OVH, Contabo or DigitalOcean, with generous bundled bandwidth and predictable pricing. A single 4-core box with 8 GB of memory serves a surprising amount of traffic (tens of thousands of daily visitors for an ordinary application) and costs less per month than the free tier's overage on a serverless platform.\n\nThe honest trade is that you own the operating system. Given the first module of this course, that is now within your reach, and for many projects it is both the cheapest and the most understandable option.\n\n## Read the exit before the entry\n\nBefore adopting anything managed, ask three questions:\n\n- **Can I get my data out, in a usable format, without asking permission?** A database with a standard dump command, yes. A proprietary store with an export queue and a support ticket, be careful.\n- **What is the egress cost of leaving?** Sometimes thousands of dollars, entirely by design.\n- **Is there a compatible alternative?** S3-compatible storage, standard Postgres and standard Redis protocols mean the switch is configuration. A vendor-specific service means a rewrite.\n\nLock-in is not automatically bad (a service that saves you a hundred hours a year has earned some) but it should be entered knowingly, and written down in the decisions document from the handover lesson.\n\n## The rule of thumb\n\nBuy the thing whose failure would ruin your weekend. Run the thing whose failure means restarting a process. Revisit once a year, because both your traffic and the prices move, and a decision that was right at fifty users is not automatically right at fifty thousand."},"check":{"question":"A solo maintainer moves Postgres from a managed service to their own VPS, saving $30 a month. Which cost most reliably appears afterwards, regardless of skill?","options":[{"text":"Higher latency, since the database is no longer on optimised hardware","correct":false,"tempting":"A local database on the same machine is often faster, not slower; performance is not the predictable cost here."},{"text":"The recurring obligation to take backups, test restores, patch and perform major-version upgrades","correct":true},{"text":"Loss of the ability to scale, since a VPS cannot be resized","correct":false,"tempting":"Most VPS providers resize in minutes; capacity is a solvable problem and not the standing cost of ownership."},{"text":"Higher egress charges, since traffic now leaves a different network","correct":false,"tempting":"Bandwidth on a VPS is usually cheaper and bundled; egress is a reason to move to one, not a consequence of doing so."}]},"prev":{"slug":"when-somebody-reports-your-users","title":"The email about one of your users","url":"https://addaly.com/learn/cloud-and-shipping/when-somebody-reports-your-users"},"next":{"slug":"upgrades-and-end-of-life","title":"The upgrade you keep postponing","url":"https://addaly.com/learn/cloud-and-shipping/upgrades-and-end-of-life"},"authorship":"Founder and series editor: Dr Mustafa Mun. Written by AI models to a written standard. Exam keys checked blind by a second model: 3,665 of 3,666 agreed. Academic review invited.","review":{"status":"Draft, open for academic review"},"cite":"Addaly (2026) 'What to run yourself, and what to pay for', in Shipping It. Edited by M. Mun. Addaly. Available at: https://addaly.com/learn/cloud-and-shipping/managed-or-self-hosted (Accessed: 13 October 2026).","licence":{"name":"CC BY-NC-SA 4.0","url":"https://creativecommons.org/licenses/by-nc-sa/4.0/"},"reader":{"schema":1,"title":"What to run yourself, and what to pay for","courseTitle":"Shipping It","module":{"index":8,"slug":"running-it-for-years","title":"Running it for years"},"answer":null,"keyIdea":"Compare money against hours of attention, not money against money: buy the stateful things whose backup, restore and upgrade obligations would eat your weekends, run the stateless ones that recover by restarting, and check how you would leave before you join.","hero":{"kind":"plate","image":null,"alt":null,"caption":null},"blocks":[{"t":"h2","id":"the-comparison-people-make-is-the-wrong-one","runs":[{"text":"The comparison people make is the wrong one"}]},{"t":"p","runs":[{"text":"A managed Postgres costs perhaps $25 a month at small size. The same database on a VPS you already rent costs nothing extra. So self-hosting saves $300 a year, and people take that deal without writing down the other side of it."}]},{"t":"p","runs":[{"text":"The other side is a list, and it is the same list every time: installing and configuring it, taking backups, testing a restore, applying security patches, upgrading major versions, monitoring disk and connections, tuning when it slows down, and being the person who fixes it at 2am. Put an hour a month against that (which is optimistic) and at any realistic hourly value the managed service was cheaper before you finished reading this paragraph."}]},{"t":"p","runs":[{"text":"That is not an argument for buying everything. It is an argument for comparing the same two columns each time: "},{"text":"money","b":true},{"text":" and "},{"text":"hours of your attention","b":true},{"text":", where attention is the scarcer one for a small team."}]},{"t":"h2","id":"the-three-questions-that-decide-it","runs":[{"text":"The three questions that decide it"}]},{"t":"ol","start":1,"items":[[{"text":"Is this thing stateful?","b":true},{"text":" Stateless services are easy to run yourself: if one dies, start another. Stateful ones (databases, queues with durable state, object storage, search indexes) carry backup, restore, replication and upgrade obligations that dominate the work. "},{"text":"Buy state, run stateless","b":true},{"text":" is the single most useful heuristic here."}],[{"text":"What happens at 3am if it breaks?","b":true},{"text":" If the answer is “I do not know how to fix it”, either learn before you depend on it, or pay somebody whose job that is."}],[{"text":"Would running it teach you something you need?","b":true},{"text":" A genuine reason. Running Postgres yourself for a year teaches you more about databases than any course. Do it on a side project, not on the thing with users."}]]},{"t":"h2","id":"what-is-usually-worth-paying-for-at-small-scale","runs":[{"text":"What is usually worth paying for, at small scale"}]},{"t":"ul","items":[[{"text":"The database.","b":true},{"text":" Backups, point-in-time recovery, failover and version upgrades, for the price of two coffees a week. This is the best value on the list."}],[{"text":"Email delivery.","b":true},{"text":" The deliverability lesson explained why running your own mail server is a losing fight."}],[{"text":"TLS certificates and DNS.","b":true},{"text":" Free or nearly, and automated."}],[{"text":"Error tracking and uptime checks.","b":true},{"text":" Free tiers are generous, and self-hosting your monitoring on the machine being monitored is a known trap."}],[{"text":"Object storage.","b":true},{"text":" Durability you cannot easily reproduce."}]]},{"t":"h2","id":"what-is-usually-fine-to-run-yourself","runs":[{"text":"What is usually fine to run yourself"}]},{"t":"ul","items":[[{"text":"Your own application.","b":true},{"text":" Obviously."}],[{"text":"A cache.","b":true},{"text":" Redis or Valkey on the same box, treated as disposable, is low-maintenance because losing it is survivable by design."}],[{"text":"A reverse proxy.","b":true},{"text":" Caddy or nginx. One config file, rarely touched."}],[{"text":"Batch jobs and workers.","b":true},{"text":" Stateless, restartable, cheap."}],[{"text":"Small internal tools.","b":true},{"text":" Metabase, a status page, a wiki."}]]},{"t":"h2","id":"the-middle-ground-people-forget","runs":[{"text":"The middle ground people forget"}]},{"t":"p","runs":[{"text":"Between “my own machine” and “a hyperscaler” is a large and underrated space: a €5 to €20 VPS from Hetzner, OVH, Contabo or DigitalOcean, with generous bundled bandwidth and predictable pricing. A single 4-core box with 8 GB of memory serves a surprising amount of traffic (tens of thousands of daily visitors for an ordinary application) and costs less per month than the free tier’s overage on a serverless platform."}]},{"t":"p","runs":[{"text":"The honest trade is that you own the operating system. Given the first module of this course, that is now within your reach, and for many projects it is both the cheapest and the most understandable option."}]},{"t":"h2","id":"read-the-exit-before-the-entry","runs":[{"text":"Read the exit before the entry"}]},{"t":"p","runs":[{"text":"Before adopting anything managed, ask three questions:"}]},{"t":"ul","items":[[{"text":"Can I get my data out, in a usable format, without asking permission?","b":true},{"text":" A database with a standard dump command, yes. A proprietary store with an export queue and a support ticket, be careful."}],[{"text":"What is the egress cost of leaving?","b":true},{"text":" Sometimes thousands of dollars, entirely by design."}],[{"text":"Is there a compatible alternative?","b":true},{"text":" S3-compatible storage, standard Postgres and standard Redis protocols mean the switch is configuration. A vendor-specific service means a rewrite."}]]},{"t":"p","runs":[{"text":"Lock-in is not automatically bad (a service that saves you a hundred hours a year has earned some) but it should be entered knowingly, and written down in the decisions document from the handover lesson."}]},{"t":"h2","id":"the-rule-of-thumb","runs":[{"text":"The rule of thumb"}]},{"t":"p","runs":[{"text":"Buy the thing whose failure would ruin your weekend. Run the thing whose failure means restarting a process. Revisit once a year, because both your traffic and the prices move, and a decision that was right at fifty users is not automatically right at fifty thousand."}]}],"check":{"question":[{"text":"A solo maintainer moves Postgres from a managed service to their own VPS, saving $30 a month. Which cost most reliably appears afterwards, regardless of skill?"}],"options":[{"text":[{"text":"Higher latency, since the database is no longer on optimised hardware"}],"correct":false,"tempting":[{"text":"A local database on the same machine is often faster, not slower; performance is not the predictable cost here."}]},{"text":[{"text":"The recurring obligation to take backups, test restores, patch and perform major-version upgrades"}],"correct":true,"tempting":null},{"text":[{"text":"Loss of the ability to scale, since a VPS cannot be resized"}],"correct":false,"tempting":[{"text":"Most VPS providers resize in minutes; capacity is a solvable problem and not the standing cost of ownership."}]},{"text":[{"text":"Higher egress charges, since traffic now leaves a different network"}],"correct":false,"tempting":[{"text":"Bandwidth on a VPS is usually cheaper and bundled; egress is a reason to move to one, not a consequence of doing so."}]}],"order":[2,0,1,3],"why":null},"prev":{"slug":"when-somebody-reports-your-users","title":"The email about one of your users","minutes":9},"next":{"slug":"upgrades-and-end-of-life","title":"The upgrade you keep postponing","minutes":9}}}