Amazon MSK vs self-managed Apache Kafka

Amazon MSK and self-managed Apache Kafka both run the same open-source project. The choice turns on who operates brokers, upgrades, security integration and data location.

On this page

Amazon MSK vs self-managed Apache Kafka: when each fits

MSK fits teams that want AWS to run the brokers, handle patching and storage, and integrate with IAM, while the team focuses on topics, producers and consumers. Self-managed Apache Kafka fits teams that already have Kafka operations capacity and a concrete reason to control hosting, Kafka versions or physical placement. A renewal, an MSK cost review, a data residency requirement or a wish to avoid AWS-specific IAM is usually the trigger, but the trigger alone does not settle the choice. Start by writing down who carries the pager for broker failures, disk pressure and rebalances, and whether that person or team can do it at 3 a.m. without a vendor on the other end.

Four drivers decide most cases. First, on-call: who owns broker incidents, controller failover and partition reassignment. Second, upgrade cadence: Apache Kafka publishes releases roughly every four months, and rolling upgrades are supported from each of the last three releases, so a team that upgrades rarely will fall out of the supported window. Confirm how quickly MSK offers each Kafka version you need and whether you can pin one. Third, authentication: if your clients already rely on IAM roles, moving to Kafka's native SASL or mTLS means rebuilding that access model. Kafka supports SSL and SASL (including SCRAM-SHA-256, SCRAM-SHA-512 and OAUTHBEARER), so the question is whether your identity team will run it. Fourth, data location: confirm where regulators and contracts require topic data and backups to sit, including any on-premises systems that produce it.

Run a short comparison before committing. Ask your team to estimate its monthly Kafka hours for patching, capacity planning, monitoring and incident response, then compare that with the MSK line items on your current bill and the staff time you would need to replace them. Ask your security team which authentication model they will accept and which audit evidence they need from each option. If the answer to on-call and upgrade cadence is that nobody has time, MSK is usually the lower-risk path. If you have a platform team, an on-premises requirement or a clear need to pin versions, self-managed Kafka becomes a realistic option, and the migration and cost pages in this group go into the next steps.

Which option fits which scenario

This table matches common operating contexts to the option that usually fits better: MSK provisioned or Express, or Kafka you run yourself on EC2, Kubernetes with Strimzi, or your own hardware. Read each row as a condition to test against your estate, not a verdict, and confirm the points that depend on your own environment before deciding.

ScenarioBetter fitReason
AWS-only estate with IAM everywhereAmazon MSKIAM access control and AWS-native networking reduce the number of identity systems to run. Self-managed Kafka can still use SASL or mTLS, so the gain depends on how much your teams rely on IAM.
On-premises or hybrid plantsSelf-managed Kafka on owned hardwareBrokers next to factories or branches keep local systems working when the WAN link is down. Mirror to cloud clusters where needed, using MirrorMaker 2.
Strict version controlSelf-managed KafkaYou choose the exact release and upgrade timing. Confirm which releases MSK offers and its support windows for your region before you rely on this.
Small platform team with no Kafka experienceAmazon MSKBroker patching, storage and cluster hardware are handled by AWS. You still own topics, ACLs, client configuration and consumer lag, so plan for that work either way.
Multi-cloud or cloud-neutral estateSelf-managed KafkaOne Kafka deployment model works across clouds and data centers, while MSK ties operations to AWS. Confirm how your networking and identity will span providers.
Teams already running Kubernetes with StrimziSelf-managed Kafka on StrimziExisting Kubernetes skills, GitOps pipelines and monitoring stacks carry over. Expect to own broker upgrades, storage and etcd-free KRaft operations inside your cluster.

Who picks the Kafka version and when it upgrades

With self-managed Apache Kafka, your team chooses the release and the moment it changes. The Kafka project aims for three releases a year, one every four months, and it issues bugfix releases only for supported versions. Rolling upgrades are supported from each release in the past year, which means the last three releases, up to the latest. Staying inside that window is the main upgrade rule you own, because a cluster that falls outside it needs a multi-step path to catch up. Check the Kafka downloads page for the currently supported lines before you pick a target, and schedule a yearly review so the cluster never drifts out of the window.

The version decision also depends on how your cluster stores metadata. Apache Kafka 4.0 supports only KRaft mode, and ZooKeeper mode has been removed, so any ZooKeeper-based cluster must migrate to KRaft before it moves to 4.x. The upgrade notes also recommend that KRaft clusters older than 3.3.x first move to 3.9.x before going to 4.x. Build this into your plan as a two-stage upgrade with its own testing and rollback steps. Confirm the exact migration procedure in the Kafka 4.3 upgrade notes for your starting version, and check Java 17 requirements for brokers and Connect workers before scheduling the change.

Amazon MSK works differently: AWS sets which Kafka versions are available on MSK and runs the upgrade windows you can schedule or defer. Your team gets the benefit of AWS-controlled timing but less control over when a version arrives or leaves. Before you compare the two models, confirm the current MSK version support, end-of-support dates and upgrade options in AWS documentation for your cluster type, including whether provisioned and Express clusters follow the same lifecycle. Record those dates next to your own upgrade calendar so the comparison reflects the actual support windows your workloads will face.

Where self-managed Kafka runs: EC2, Kubernetes with Strimzi or your hardware

Running Kafka on EC2 gives you the most direct replacement for MSK provisioned brokers. You choose the instance types, the EBS volumes and the network layout, and you install Apache Kafka from the Apache Software Foundation release under the Apache License 2.0. Your team then owns everything MSK currently handles for you, from broker restarts to certificate rotation.

  • Brokers and storage: Your team sizes instances, provisions EBS volumes, sets log retention and runs rolling restarts. Kafka runs in KRaft mode, so there is no separate ZooKeeper fleet to operate.
  • Network and availability zones: You design subnets, security groups and placement across zones, and you decide how producers and consumers reach each broker. Cross-zone traffic is a cost line you must model yourself.
  • Certificates and authentication: You issue and rotate TLS certificates and configure SASL mechanisms such as SCRAM-SHA-512 or OAUTHBEARER, or mTLS, in place of IAM authentication.
  • Monitoring and patching: You collect broker, controller and consumer lag metrics, and you patch the operating system and Java runtime. Kafka 4.0 and later require Java 17 for brokers.
  • Upgrades: Plan rolling upgrades from a supported release in the last year to the latest one.

EC2 fits teams that already run VM fleets, want full control of instance sizing, and have staff who manage Linux and infrastructure as code. Confirm with your AWS account team and your own environment how EBS and networking costs will change compared with your current MSK bill.

IAM versus SASL, mTLS and ACLs in practice

Authentication and authorization decide who can produce to and consume from a Kafka cluster, and they are where MSK and self-managed Kafka differ most in day-to-day operation. The cards below compare the MSK IAM option with the SASL mechanisms, TLS and mutual TLS, and KRaft ACLs that a self-managed cluster provides. Read them together, because the choices you make for one control affect the others.

MSK IAM authentication

IAM access control is the authentication path most tightly integrated with AWS. Clients authenticate with IAM identities, so access follows the same roles, policies and audit trails your AWS teams already manage. The trade-off is that the mechanism is tied to AWS, so applications running outside AWS, or moving to self-managed brokers, must be reworked to use a different SASL mechanism. Before you design around it, confirm with AWS which authentication methods apply to your specific MSK cluster type, because provisioned, Express and serverless clusters do not all offer the same set.

Kafka security overview

SASL mechanisms in Kafka

Apache Kafka supports GSSAPI (Kerberos), PLAIN, SCRAM-SHA-256, SCRAM-SHA-512 and OAUTHBEARER as SASL mechanisms. GSSAPI fits sites that already run Kerberos, SCRAM suits teams that want password-based credentials stored in the cluster, and OAUTHBEARER fits organizations that issue tokens from a central identity provider. PLAIN sends credentials in a form that is only safe over TLS, so it should be paired with encrypted listeners. Each mechanism changes client configuration, secret rotation and onboarding work, so map every application to one mechanism before migration.

Kafka security overview

TLS and mutual TLS on SSL listeners

Kafka encrypts traffic between clients, brokers and tools through SSL/TLS listeners, and mutual TLS adds client certificates so each client proves its identity. Certificate issuance, rotation and revocation then become your team's responsibility, usually through an internal certificate authority or a secrets platform. Plan for certificate expiry in your on-call runbooks, since an expired broker or client certificate stops traffic. Confirm with AWS how MSK handles TLS and client certificates for your cluster type, because the options and the certificate management boundary differ from a cluster you operate yourself.

KRaft ACLs and default access

In KRaft clusters the StandardAuthorizer stores ACLs in the cluster metadata log, so authorization is managed as part of the cluster itself. By default, resources without an ACL are restricted to super users unless allow.everyone.if.no.acl.found is set to true. Leaving that setting enabled can quietly open topics that nobody reviewed. Security is optional in Kafka, so a listener can run unsecured or mix secured and unsecured listeners. Your team must enforce encryption, authentication and authorization on every listener, and verify the result with a test from an unprivileged client.

Kafka authorization docs

Data location, residency and compliance evidence

MSK keeps Kafka brokers inside your AWS account and in the AWS region you choose, so data residency is largely a question of which region and which account boundaries you configure. Self-managed Kafka gives you a wider set of options: a cloud of your choice, a colocation facility, an on-premises data center or an air-gapped network with no internet path. Neither model is automatically compliant. Before you decide, confirm with your legal and compliance teams where topic data, consumer offsets, broker logs and backups may legally live, and whether any replication target (such as a cloud cluster used for analytics) falls inside the same residency boundary.

Auditors will ask who controls the keys, the logs and the change history. With MSK, encryption at rest uses AWS KMS, so confirm whether you use an AWS-managed key or a customer managed key, who holds key policy permissions and whether key deletion is restricted. In a self-managed cluster, you own the disk encryption, the TLS certificate authority and the key rotation schedule, so those controls and their owners must be written down. For access logs, map each control plane and data plane event (broker authentication, ACL changes, topic configuration edits) to a log store you control, and check retention against your policy. For backups, decide which system holds topic snapshots or MirrorMaker 2 replicas, where they are stored and who can restore them. For upgrades, keep a dated record of each Kafka version change, the approval and the rollback plan. The Apache Kafka upgrade notes are the natural starting point for those records.

DeployOpen prepares the systems, configuration, access controls, logging and evidence that your compliance assessors review for either model. DeployOpen does not issue audit reports, attestations or certifications. Independent auditors and certification bodies make those determinations, so ask any implementation partner, including DeployOpen, to show the evidence it will produce and the controls it will leave in place for your team to operate.

Cost components on each side and what drives them

Running Kafka yourself moves cost from one AWS bill into several line items: compute, disks, network, connectors, monitoring and people. Each row below names who is paid for what, whether the cost is one-time or recurring, and what moves it up or down. Model each line with your own throughput, retention and partition counts, and ask MSK pricing for a written quote before comparing totals.

Broker compute

On MSK, you pay for broker instance hours on a provisioned or Express cluster, or for partition and throughput usage on Serverless, so the size and count of brokers is the main recurring line. Self-managed Kafka costs the same work as EC2 instances, bare metal or Kubernetes worker nodes that you buy or reserve yourself. Check how many brokers each option needs for your peak throughput, replication factor and failure headroom, not average load. Tip: size for peak and failure, not average, because an under-provisioned cluster during a broker loss is the costliest case.

Kafka geo-replication docs

Storage and retention

Storage is billed on MSK per GB of broker storage, with tiered or low-cost storage options that change the retention economics. Self-managed storage is the disks, volumes or SAN capacity you provision, plus the snapshot or backup copies you keep. Retention period and replication factor multiply the stored bytes, so each extra day of retention costs more than it first appears. Ask MSK for the current storage and tiered storage rates in your region, and confirm which storage tier your retention requires.

Data transfer

Cross-AZ replication traffic, client traffic to brokers, and any cross-region mirroring are billed as data transfer on AWS, and they recur with every byte produced. On self-managed Kafka, transfer is the same traffic seen through your cloud or data center network, so the bill depends on where producers, consumers and brokers sit. Placing clients in the same zones as partition leaders and minimizing cross-region mirroring usually reduces this line. Ask for a transfer estimate that separates cross-AZ, internet and cross-region traffic.

Connectors and Connect workers

MSK Connect bills connector capacity in MCU-hours, so connector count and autoscaling settings recur as a monthly cost. Self-managed Kafka Connect runs as worker processes on VMs or Kubernetes pods that you size, patch and scale, with cost tied to compute and the staff time to maintain plugins. Costs go up with more connectors, higher task parallelism and always-on workers, and fall when you consolidate connectors. Confirm the MCU-hour rate and the connector plugins you depend on before you count them as a like-for-like cost.

Kubernetes nodes or servers

If you run Strimzi, the Kubernetes control plane, worker nodes, load balancers and etcd become your cost, while MSK bundles the control plane into the managed service. Self-managed hardware adds one-time purchase, rack, power and support contracts, and recurring hosting costs. Adding a separate KRaft controller tier or a larger Kubernetes footprint raises the count of nodes you pay for. Ask whether your platform team already runs spare capacity that can absorb Kafka without new hardware.

Monitoring and logs

MSK charges for enhanced monitoring levels and log delivery to CloudWatch or other destinations, which grows with the number of metrics and log volume. Self-managed monitoring costs the Prometheus, Grafana, log storage and alerting infrastructure you run, plus the time to build dashboards. Costs rise with metric cardinality, retention of logs and per-topic metrics, and fall when you cap label sets and sample logs. Ask which monitoring level your MSK quote assumes and how long you must retain broker logs for audit.

Kafka operations staff

This is the largest and least visible line: upgrades, KRaft and version planning, certificate and SASL rotation, ACL management, capacity work and on-call response. MSK reduces host-level work but still leaves you with topic design, client upgrades, IAM or mTLS policy and consumer lag incidents. Self-managed Kafka adds broker lifecycle, controller and storage operations on top of that, so the cost is recurring people time and training, not a one-time fee. Estimate the hours per month your team already spends on messaging, and ask an implementation partner for a written scope that names who carries the on-call rotation.

What a move from MSK to self-managed Kafka involves

The sequence moves topics, configuration, access rules and consumer positions to a Kafka cluster you run, then switches clients over in an order that keeps data flowing and gives you a rollback path. Each step ends with a check you can verify before the next one starts.

  1. Inventory topics, configs, ACLs and connectors

    The platform or Kafka team exports the full picture from the MSK cluster: topic names, partition counts, replication factors, topic-level configurations, consumer groups, ACLs tied to IAM principals, and every MSK Connect connector with its plugin and settings. Application owners confirm which producers and consumers depend on each topic. The step is done when someone can list every topic and consumer group and every owner has signed off on the list. Ask your vendor or the MSK documentation to confirm which IAM policies map to Kafka ACLs in your setup, because the mapping is not one-to-one.

  2. Stand up the target Kafka cluster

    Your infrastructure or platform team builds the target cluster on EC2, Kubernetes with Strimzi, or owned hardware, running a supported Apache Kafka release in KRaft mode. The team sets broker count, storage, TLS listeners, the SASL or mTLS authentication you chose, monitoring and backups before any data moves. Confirm the Java runtime the chosen release requires, and check the Kafka upgrade notes for the version you select. The step is done when a test producer and consumer can connect over the secured listeners and the cluster passes your load and failover tests.

  3. Replicate with MirrorMaker 2 and verify offsets

    The team runs MirrorMaker 2, which is built on Kafka Connect, to copy topic data, topic configurations, consumer group offsets and ACLs from MSK to the new cluster. Replication runs continuously so the target stays close to the source until cutover. Compare message counts, partition offsets and checksums sampled from both clusters, and confirm that translated consumer group offsets are present on the target. The step is done when lag between clusters is stable and the sampled data matches. Test the offset translation with a non-critical consumer group first.

  4. Replace IAM authentication with SASL or mTLS

    MSK clients that authenticate with IAM need a new credential path on the target cluster. Security engineers choose between SASL mechanisms such as SCRAM-SHA-512 or OAUTHBEARER and mutual TLS, based on your identity provider and certificate authority, and then issue credentials to each application through your secrets store. Recreate the matching ACLs for each principal and test that each application can produce and consume with its new identity and nothing more. The step is done when every service has working credentials, every ACL test passes and no client still depends on IAM signing.

  5. Move MSK Connect connectors to Kafka Connect

    The team deploys Kafka Connect workers on the target platform and recreates each connector from the inventory, moving connector plugins, configuration and secrets into your own deployment. Connectors that read from or write to external systems need their offsets and internal topics handled carefully so they do not reprocess or skip data. Pause each source connector on MSK before its twin starts on the target, and confirm the sink connectors resume from the expected position. The step is done when each connector runs on the target, its output matches the source, and the MSK copy is stopped.

  6. Switch producers and consumers in a safe order

    Cut over consumers first only when the target already holds the data they need, then move producers, so no message is written to a cluster that no one reads. Move one application group at a time, starting with low-risk services, and keep MSK replication running in reverse or on standby so you can roll back. Watch consumer lag, error rates and broker health during each switch. The step is done when every producer and consumer points at the new cluster, lag is at normal levels, and the MSK cluster is no longer serving traffic and is ready for decommissioning after your retention and audit requirements are met.

How MirrorMaker 2 moves traffic between clusters

The flow starts at the MSK source cluster, where MirrorMaker 2 runs on Kafka Connect inside the client's environment and reads topics, configurations, consumer group offsets and ACLs. It writes them to the self-managed target cluster, which can be checked before any traffic moves. Cutover then happens in phases: producers switch first, consumers follow once the target has caught up and offsets are verified. Check that the MSK IAM principals are replaced by the target's SASL or mTLS identities at each step.

MirrorMaker 2 copies data from MSK to the target, and clients move in phases.

Questions buyers ask before choosing self-managed Kafka

How much more effort is self-managed Kafka than Amazon MSK?

Self-managed Kafka moves broker patching, capacity planning, storage management, certificate handling, monitoring and upgrade planning from AWS to your team, so the recurring effort is higher than the MSK service fee alone suggests. MSK takes over parts of the broker lifecycle, while a self-run cluster needs an owner for each of them. The gap is largest during upgrades and incidents, and it shrinks when the platform team already runs Kubernetes and observability stacks. Ask any provider to split its estimate into build work and recurring operations so you can compare each line with what MSK does for you.

Can a small team run self-managed Kafka without dedicated streaming specialists?

A small team can run Kafka if it already operates Kubernetes or Linux infrastructure, has someone who understands partitions, replication and consumer groups, and has a documented on-call rota. The Kafka project publishes supported releases on a regular cadence, so the team must plan an upgrade every few months rather than waiting for a crisis. Teams without any Kafka experience should budget for training or outside support during the first year. The deciding factors are the number of clusters, the number of producers and consumers, and how quickly the business expects recovery from a broker failure.

How long does a migration from MSK take, and what drives the timeline?

The timeline depends on the number of topics, the data volume to replicate, the number of applications that must switch bootstrap servers, and how many MSK Connect connectors need to be rebuilt. MirrorMaker 2 can replicate topics, configurations, consumer offsets and ACLs between clusters, which lets applications move in stages. Authentication changes, such as replacing IAM with SASL or mTLS, add testing work on each client. Agree on a written scope and a cutover plan with a rollback path before any date is set, and ask for the timeline as a fixed scope document.

Can we keep IAM authentication after leaving MSK?

IAM access control for MSK is an AWS feature, so it does not carry over to a self-managed cluster as-is. Apache Kafka authenticates clients with SSL or SASL, and the documented SASL mechanisms include GSSAPI (Kerberos), PLAIN, SCRAM-SHA-256, SCRAM-SHA-512 and OAUTHBEARER. Teams that want a single identity model often pair OAUTHBEARER with their existing identity provider, or use mTLS with certificates issued by an internal authority. Each choice changes client configuration, secret distribution and ACL design, so confirm the target model before rewriting producers and consumers.

Which skills does the team need for self-managed Kafka?

The work needs Kafka operations skills, Kubernetes or Linux administration, security engineering for TLS and SASL, and an observability practice that covers brokers, consumers and disks. In KRaft mode, the team must understand metadata quorum, controller roles and ACLs stored in the cluster metadata log. Upgrade planning requires reading each release's upgrade notes, since Kafka 4.0 removed ZooKeeper mode and requires Java 17 for brokers. Kubernetes itself has its own skew and etcd backup duties, so platform staff should be comfortable with those as well.

Can our own engineers do the implementation, or do we need a partner?

Your engineers can do the work if they have the skills listed above and enough time to run a parallel cutover. A partner adds value when the platform team is small, the compliance evidence must be prepared alongside the build, or the migration must finish within a fixed window. DeployOpen plans, implements, hardens, backs up, upgrades and documents self-hosted open-source platforms inside your own cloud accounts or data centers, so ownership of the cluster can stay with your team. Decide early which parts you want to keep in-house, such as on-call, and which you want to hand over.

What does a fixed-scope quote from DeployOpen cover?

A fixed-scope quote covers the agreed scope, deliverables and timeline, written down before work starts. For a Kafka move, that normally means the target architecture, the cluster build in your environment, the authentication design, the MirrorMaker 2 replication plan, the connector and client switchover order, hardening, backup and restore testing, documentation and handover. Work outside the written scope, such as ongoing operations or continuous testing, is handled as a separate retainer. DeployOpen does not publish a price list, so ask for the quote to list each deliverable, the assumptions behind the timeline and the items excluded.

How DeployOpen helps evaluate, implement or migrate Kafka

DeployOpen is a Chainscore Labs company that plans, implements, hardens, backs up, upgrades, documents and supports self-hosted open-source platforms inside your own infrastructure. For Amazon MSK versus self-managed Apache Kafka, the work starts with a written scope that decides whether Kafka stays on AWS, moves to your own Kubernetes or servers, or runs in a hybrid model.

How we scope

  • Engagements are fixed-scope, with scope, deliverables and timelines agreed in writing before work starts.
  • The scope inventories MSK cluster types, client authentication, topics, MSK Connect connectors and consumer groups in use.
  • We confirm the target Kafka version, KRaft status and upgrade path against the official Kafka upgrade notes for your environment.

How we build

  • We deploy Kafka in KRaft mode on your chosen platform, with TLS and SASL or mTLS settings agreed with your security team.
  • Migration work covers MirrorMaker 2 replication of topics, configurations, consumer offsets and ACLs, tested before any cutover.
  • We set up monitoring, alerting, backups and access control so your compliance and security teams can review the platform.

How we hand over

  • You receive architecture, runbooks, upgrade procedures and client switchover steps written for your own operations staff.
  • Cutover plans define the order for moving producers, consumers and connectors, with rollback steps for each stage.
  • We walk your platform and operations teams through the running system and record the evidence your auditors will ask for.

How we support

  • Ongoing support, upgrades and continuous testing are available as retainers, aligned to the release schedule you choose.
  • Security testing of brokers, clients, network exposure and access paths can be scoped as a separate, fixed engagement.
  • Before any retainer starts, we agree in writing what drives recurring effort, such as upgrade frequency and on-call coverage.

Sources and further reading

Talk to our team.

Tell us what you're working on, whether it's a deployment, an audit, a security test or a cyber range. You'll speak with an engineer who can help you scope it.

  • 30-minute call: free, with no obligation.
  • NDA on request: we can sign before you share details.
  • Clear next steps: a scope and plan after the call.