Author: Tomo

  • Becoming a Sole Proprietor in Japan: Registration, Blue-Form Taxes and Invoices for Freelance Engineers

    Becoming a Sole Proprietor in Japan: Registration, Blue-Form Taxes and Invoices for Freelance Engineers

    So you have decided to freelance in Japan. The projects, the agents and the rates are the exciting part, but before any of that pays you, there is a quieter set of decisions to make: how you register your business, how you file your taxes, and how you handle invoices. None of it is difficult, but almost all of it has deadlines — much easier to meet before you start than after.

    I am a Japanese freelance engineer working as a sole proprietor — the standard legal form for an independent engineer in Japan, and the one most of the freelance market assumes you are using. This article walks through the registration and tax basics in the order you will meet them, based on the rules in 2026.

    One important caveat: this article is general information, not tax advice, and not a substitute for professional advice about your own situation. Use it as a map, and confirm the details that matter with a tax accountant (zeirishi).

    What “sole proprietor” actually means

    A sole proprietor's small business beside a corporation

    A sole proprietor (kojin jigyonushi) is not a company. There is no separate legal entity, no registration at a legal affairs bureau, and no capital to deposit. You and your business are the same legal person: its income is your personal income, and its debts are your personal debts.

    That simplicity is why it is the default for freelance engineers: you can start with a single form, and your bookkeeping obligations are lighter than a corporation’s. The trade-off is that everything lands on your personal tax return, which is why the filing choices below matter more than new freelancers expect.

    The alternative — incorporating — is a real option once income grows, and a short section at the end covers it. But almost every engineer I know started as a sole proprietor, and many stay that way for years. For the industry context — how sole proprietors sit inside the SIer and agent structure — see my explainer on how Japan’s IT industry actually works.

    Step one: the opening notification (kaigyo todoke)

    Filing the opening notification at the tax office

    Your first form is the notification of opening a business, usually called the kaigyo todoke. You file it with the tax office (zeimusho) for your home address, within one month of starting your business — in practice, your first day of independent work. You can file on paper at the tax office or by post, or electronically through e-Tax, the National Tax Agency’s online system.

    Filing is free, and the form is short: your name and address, the type of business, the date you opened, and whether you plan to hire anyone. Most engineers describe the business type in plain terms such as software development or IT consulting.

    Two practical points. First, keep the stamped copy (or the e-Tax receipt) safe: banks and agents sometimes ask for proof of registration, and this document is that proof. Second, there is a parallel notification to your prefecture for the local business tax (kojin jigyozei), which many people file at the same time. If you miss the one-month window the tax office will still accept the form — but delay here usually makes you late for the next form too, and that one has money attached.

    Step two: choose the blue form — and mind its deadline

    The blue-form application and its deadline

    Every sole proprietor files an annual income tax return, and you choose one of two colours. The white form (shiroiro shinkoku) is the default: simple, no prior approval needed, and no special deduction. The blue form (aoiro shinkoku) requires approval in advance, proper bookkeeping and a balance sheet — and in exchange gives you a substantial special deduction and several other advantages.

    The catch is the application deadline. Your application for blue-form approval (aoiro shinkoku shonin shinseisho) must be accepted by 15 March of the year you want to use it — or, if you are newly opening, within two months of your opening date. Miss it, and you are on the white form for that whole year no matter how good your books are. It is the most expensive piece of paper to forget in your first year.

    For engineers, the blue form is usually the right choice: engineering income is high enough that the deduction is worth real money, and the bookkeeping it requires is the same bookkeeping you should be doing anyway. The next section explains what the deduction is actually worth.

    The blue-form deduction: three tiers

    Three tiers of the blue-form deduction

    The blue-form special deduction comes in three tiers, and which one you qualify for depends on how you keep your books and how you file. The tiers, in descending order, are:

    • ¥650,000 — proper double-entry books and the required financial statements, plus either filing through e-Tax or storing records as electronic books under the electronic bookkeeping rules.
    • ¥550,000 — the same double-entry books and statements, but filed on paper without the electronic element.
    • ¥100,000 — a blue-form return with simpler records that do not meet the full double-entry standard.

    The gap between the top and bottom tiers is ¥550,000 of deduction, worth over ¥100,000 in tax at typical engineer income levels. That is a remarkable amount of money to leave behind for want of an e-Tax account and decent accounting software — and most cloud accounting tools aimed at freelancers in Japan are built to produce exactly the statements the ¥650,000 tier requires. The blue form also lets you carry a business loss forward for up to three years, and use a lump-sum depreciation rule for smaller equipment purchases.

    Bookkeeping and the annual return

    Bookkeeping and the annual tax return

    Your tax year is the calendar year, and your final tax return (kakutei shinkoku) is due between mid-February and mid-March of the following year. The return reports your business income — revenue minus expenses — combined with any other income and taxed as personal income. If you worked as an employee for part of the year, that salary goes on the same return, which surprises some people in their transition year.

    Bookkeeping is the daily discipline behind the return. Every invoice, payment and expense needs a record, and the blue form’s higher tiers require proper double-entry records rather than a simple cash notebook. In practice, engineers connect their business bank account and card to cloud accounting software and categorise transactions as they go, rather than reconstructing a year of finances in February.

    One more habit is worth starting on day one: keep business money separate, in a dedicated bank account and card. It costs nothing, makes the bookkeeping almost automatic, and removes the temptation to run personal spending through the business.

    Pension and health insurance after you leave employment

    Pension and health insurance as a sole proprietor

    While you are a company employee, your employer enrols you in the employees’ pension and health insurance and pays half the premiums. The day you become a sole proprietor, that stops, and two enrolments become your own responsibility — neither optional, both handled at your municipal office.

    For pension, you move to the National Pension (kokumin nenkin), a flat monthly premium paid by all self-employed residents. For health insurance, most freelancers join National Health Insurance (kokumin kenko hoken), whose premiums are calculated from your previous year’s income — why the second year of freelancing often brings a larger bill than the first. A common alternative early on is voluntary continuation (nin’i keizoku) of your former employer’s health insurance, which can be cheaper while freelance income is low — but you must apply within a short window after leaving.

    Budgeting for these is part of setting your rate: your gross monthly billing now has to cover income tax, resident tax, pension and health insurance before it is comparable to a salary. The market data in my article on freelance engineer rates in Japan (2026) will help you judge whether a rate actually leaves you better off.

    The qualified invoice system: registration is a choice

    The qualified invoice system: a choice to weigh

    Since October 2023, Japan has operated a qualified invoice system (tekikaku seikyusho, usually just “the invoice system”). Under it, a business client can only claim full input tax credit on consumption tax if its invoice comes from a registered qualified invoice issuer. Registration is voluntary — but registering makes you a consumption-tax taxpayer even at income levels that would otherwise be exempt, so the decision has a real cost on your side too.

    For freelance engineers, the practical question is what your clients and agents expect. Many larger clients and agents strongly prefer — and some effectively require — invoices from registered issuers, because an unregistered freelancer’s invoice reduces the credit they can claim. Others accept unregistered invoices, sometimes while negotiating the rate to reflect the difference. There is no universal answer; there is only the answer your market segment gives you.

    So ask agents about their policy before you sign, not after your first invoice is rejected or discounted. Transitional measures have softened the credit reduction for unregistered suppliers over the system’s first years, and the details keep being adjusted — another point to confirm with a tax accountant against your client mix.

    What counts as a business expense

    Everyday business expenses for an engineer

    An expense is deductible if it is necessary for earning your business income, and for engineers the everyday list is familiar: hardware, software and cloud subscriptions, home internet and phone (in proportion to business use), co-working costs, books and courses, certification exam fees, travel to client sites, and your tax accountant’s fees. Equipment above a certain price may need to be depreciated over several years rather than expensed at once, though the blue form’s lump-sum rule covers many smaller purchases.

    The discipline that matters is evidence and proportion. Keep the receipt or invoice for everything, record what it was for, and where an expense is mixed — a home internet connection, a laptop also used personally — claim a reasonable business share and be able to explain how you arrived at it. “Reasonable and explainable” is the standard every line should meet.

    When incorporating starts to make sense

    From sole proprietor to corporation

    At some point you will hear about hōjin nari — converting into a corporation (typically a GK or KK) that you own and draw a salary from. The logic is tax arithmetic: personal income tax is progressive, while a corporation pays its own flatter tax and pays you a salary that is itself deductible. Beyond a certain sustained profit level, the split can save money, and a corporation can also look more substantial to some clients.

    Against that stand real costs: incorporation fees, a corporate tax return that effectively requires a tax accountant, social insurance enrolment as an employee of your own company, and a permanent layer of administration. The break-even is usually discussed in terms of annual profit — figures around ¥6–8 million are commonly quoted as the zone where the comparison becomes worth doing — but it depends on your income pattern and plans.

    My suggestion is sequencing, not a threshold. Start as a sole proprietor, keep clean blue-form books for a year or two, and then run the comparison with a tax accountant using your real numbers. Incorporating from a position of good records is straightforward; un-incorporating is not a door you walk back through.

    Summary

    A tidy desk with the filings done

    Becoming a sole proprietor in Japan is mostly a matter of two forms and one habit. File the opening notification within a month of starting, file the blue-form application within two months (or by 15 March), and keep proper books from the first invoice. Around those sit your pension and health insurance enrolments, a deliberate decision about invoice-system registration, and — later, with real numbers in hand — the question of whether to incorporate.

    None of this requires a professional to complete, but the choices interact with your income and clients in ways a general article cannot settle. Treat this piece as general information, not tax advice, and confirm the money decisions with a tax accountant (zeirishi) before your deadlines, not after them.

  • Upgrading Dify in Production: A Checklist for Self-Hosters

    Upgrading Dify in Production: A Checklist for Self-Hosters

    Self-hosting Dify means its release cycle becomes your release cycle. Dify ships often, and most upgrades are uneventful — but the difference between a routine upgrade and an incident is rarely the upgrade itself. It is whether you took a backup you can actually restore, rehearsed the version jump somewhere that is not production, and decided in advance what would make you roll back.

    This article is the checklist I work through when upgrading a production Dify, whether it runs as Docker Compose on one host or as the ECS Fargate architecture from this series. It is written to be printed and ticked off. The ECS and Terraform differences are collected in one section near the end, so the main flow stays the same for everyone.

    Before anything: read the release notes and the upgrade guide

    Reading the release notes before upgrading

    Dify’s own documentation is explicit on this point: choose the target release and read its upgrade guide before you run anything. Some releases are drop-in replacements; others include manual steps — a data migration to run in a particular order, a component that must be upgraded in stages first. The release notes are where that is written down, and they are the only place it is written down.

    • [ ] Target version chosen, and its image tags pinned in your configuration (never latest)
    • [ ] Release notes for the target version read, plus the notes for every version you are skipping over
    • [ ] The release’s upgrade guide read; every manual step copied into your run plan
    • [ ] Plugin compatibility checked — model and tool plugins may need their own updates alongside the core

    Skipping versions deserves one extra sentence: the further you jump, the more the intermediate steps matter. Reading three sets of release notes is tedious, and it is still cheaper than discovering a staged migration halfway through applying it.

    Phase 1: Prepare the ground

    Preparing the ground: window, config backup, secrets
    • [ ] Current version and image tags recorded — your rollback needs to name them exactly
    • [ ] Maintenance window scheduled and announced to users; indexing and scheduled workflows will pause
    • [ ] Configuration backed up: the .env file and the split env files under docker/envs/ copied somewhere safe, outside the host
    • [ ] Secrets inventory confirmed — you know where every value lives (Secrets Manager, in the Terraform setup) and none exists only in a running container

    The configuration backup is the item people skip because it feels like paperwork. It is not: those env files hold your storage settings, your vector store choice and the references to every secret. Lose them in a botched upgrade and you are reconstructing your deployment from memory, under time pressure.

    Phase 2: Back up everything that holds state

    Backing up the database, files and volumes
    • [ ] Database backed up: a snapshot (Aurora, in the managed setup) or a full dump (Compose’s bundled PostgreSQL), taken after the last writes before the window
    • [ ] File storage covered: the S3 bucket has versioning on, or the uploads volume is copied
    • [ ] Named volumes identified — you know exactly which volumes hold state, and you will keep them attached (next phase explains why)
    • [ ] Restore procedure written down, command by command, before the window opens

    An untested backup is not a backup; it is a hope. You do not need to rehearse the full restore before every upgrade — but you do need to have restored successfully at least once, and to know the exact commands. If you have never restored this system, Phase 3 is where that changes.

    Phase 3: Rehearse on staging

    Rehearsing the upgrade on staging
    • [ ] The backup restored onto a staging copy (or a throwaway instance)
    • [ ] The upgrade performed there, start to finish, including every manual step from the release notes
    • [ ] The rehearsal timed — this is how long your production window needs to be
    • [ ] Anything surprising written into the production run plan

    If you have no staging environment, build the rehearsal out of the backup itself: restore it somewhere temporary and upgrade that. A version jump that includes a database migration can fail in ways that only your data triggers — your document sizes, your vector store contents. Rehearsing on empty data proves almost nothing.

    Phase 4: Check the vector store separately

    Checking the vector store as its own upgrade
    • [ ] Vector store’s own upgrade path checked — does this release change, require or stage a vector database upgrade?
    • [ ] If the vector store migrates, its backup taken separately from the main database backup
    • [ ] A post-upgrade indexing test planned (Phase 6) — vector problems hide until something indexes

    The vector store is the component most likely to have an independent migration hiding inside a Dify upgrade. Treat it as a second upgrade nested in the first: its own release notes, its own backup, its own verification.

    Phase 5: Run the upgrade

    Running the upgrade with the same project name
    • [ ] Users notified; window open
    • [ ] New images pulled with pinned tags
    • [ ] Compose run with the same project name and the same options as always — the Dify documentation stresses this, because named volumes attach by project name; a renamed project means fresh, empty volumes and a deployment that looks wiped
    • [ ] API logs watched until database migrations complete
    • [ ] Any staged component steps executed in the order the upgrade guide specifies

    That project-name point is worth the emphasis. The most frightening upgrade failure — Dify comes up empty, no apps, no data — is usually not data loss at all: it is the stack starting against new volumes because the project name or options changed. Keep them identical and the volumes, with all your state, stay attached.

    Phase 6: Re-check plugins and providers

    Re-checking plugins and providers after the upgrade
    • [ ] Plugin list reviewed: every plugin present, enabled and on a compatible version
    • [ ] Each model provider tested with one call — a provider that validated before the upgrade can need re-authorisation after it
    • [ ] Tool integrations spot-checked in one real workflow

    Core upgrades and plugins evolve on separate clocks, and the seam between them is where quiet breakage lives. A companion guide to connecting Dify to Amazon Bedrock — the provider most AWS self-hosters will be re-checking here — is in preparation.

    Phase 7: Smoke tests

    Smoke tests moving from the surface inward
    • [ ] Administrator login works and the console loads
    • [ ] One known workflow runs end to end and returns the expected shape of result
    • [ ] A workflow with a Code node executes (this exercises the sandbox path)
    • [ ] A small document uploads to a knowledge base and finishes indexing (worker, vector store and embedding model in one action)
    • [ ] One published application answers through the service API, not just the console

    Run these in this order: they move from the surface inward, so the first failure tells you roughly which layer to look at. Only when all five pass is the window closed and the upgrade announced as done.

    Rollback: decide the triggers before you start

    Rollback: returning to the previous platform
    • [ ] Rollback defined concretely: previous image tags redeployed, database restored from the Phase 2 backup
    • [ ] Trigger conditions written down: which failures, observed for how long, mean roll back rather than fix forward
    • [ ] One person named as the decision-maker during the window

    Understand what rollback means for a database-backed platform: migrations may be one-way, so rolling back the code usually means restoring the database too — which is why the backup, not the old image tag, is the real rollback. Data written after the upgrade is the price of restoring, and that price is exactly why the trigger conditions belong on paper before the window opens, not in an argument during it.

    The ECS and Terraform variant

    The ECS and Terraform variant of the upgrade

    The checklist is identical; only the mechanics change. On the Fargate architecture, an upgrade is an image-tag change in the task definitions: edit the tags, run terraform plan, and read the diff as your change record before you apply — the plan is where a stray change to an unrelated service shows up while it is still free to fix. The API service runs migrations on boot, so the log-watching step applies unchanged.

    Rollback is correspondingly cleaner: revert to the previous task definition revision, plus the database restore if migrations ran. Aurora’s automated backups and point-in-time recovery make the restore target precise — pick the moment just before the window. Everything above about rehearsal, vector stores and smoke tests applies word for word; managed services remove chores, not decisions.

    Summary

    Upgrade complete: a calmer, higher platform

    Read the target release’s notes and upgrade guide. Back up the database, the files and the configuration — and know the restore commands. Rehearse the jump on a copy of your own data, check the vector store as a separate upgrade, run the upgrade with identical project settings, then verify plugins, providers and five smoke tests before you call it done. Decide the rollback triggers before the window opens. Do those things, and a Dify upgrade goes back to being what it should be: a calendar entry, not an incident.

  • Connecting Dify to Amazon Bedrock: Models, IAM and Region Choices

    Connecting Dify to Amazon Bedrock: Models, IAM and Region Choices

    If you self-host Dify on AWS, Amazon Bedrock is the model provider you will probably reach for first. Your applications stay inside your AWS account, access is governed by IAM rather than by an API key from another vendor, and the usage lands on the same AWS bill as the infrastructure. For client work in Japan there is a second reason: region and data-residency choices are yours to make, not a provider’s.

    The connection is not one switch, though. It is four separate things that each live in a different place: model access in the Bedrock console, a plugin inside Dify, credentials that join the two, and a region decision underneath all of it. This guide walks through them in the order that avoids the common failures. It assumes Dify is already running — if it is not, the architecture I start from is the ECS Fargate setup in this series.

    What you are actually installing

    The Bedrock plugin slotting into Dify

    The connection is a plugin: the official Amazon Bedrock plugin (published by langgenius, Dify’s own developer) from the Dify Marketplace. You are not forking Dify or running a translation proxy — the plugin registers Bedrock as a model provider inside Dify, and your applications call it like any other provider.

    One provider covers three model types: large language models for chat and completion, text-embedding models for knowledge-base indexing, and rerank models for retrieval quality. That breadth is why the setup deserves care. The same configuration will serve your chat applications, decide how every document you index is embedded, and optionally re-order search results — a mistake here is not confined to one app.

    Step 1: Enable model access in the Bedrock console

    Enabling model access in the Bedrock console

    Bedrock models are not switched on by default. In the AWS console, open Amazon Bedrock, go to the model access page, and request access to the models you intend to use. Access is granted per model and per region, so this step comes after you have picked a region (see the region section below) — enabling a model in the wrong region is the single most common reason the later steps appear to fail.

    Model availability varies by region. The catalogue in one region is not the catalogue in another, and the gap is not limited to obscure models: a current chat model may be offered in one region and absent from the next. Decide which models you need first, confirm each one is available in your chosen region, and only then build workflows around them.

    Step 2: Install the plugin in Dify

    Installing the Bedrock plugin from the Marketplace

    In Dify, open the Marketplace, find the Amazon Bedrock plugin by langgenius, and install it. Then go to Settings → Model Provider, select Amazon Bedrock, and open its setup form. That form is where the remaining steps land: it takes a region and a set of credentials, and once it validates, the models you enabled in Step 1 become selectable in your applications.

    Install the plugin before you troubleshoot missing models. A model that is enabled in the console but never appears in Dify is usually a plugin or credentials problem, while a model that appears but errors on use is usually an access or region problem. Keeping that distinction in mind halves the debugging time later.

    Step 3: Credentials — access key or IAM role

    Two credential paths: access key or IAM role

    The plugin supports two authentication paths. The first is the familiar one: an AWS access key and secret key, with an optional session token if you are using temporary credentials. The second is IAM role authentication, where the plugin obtains credentials from the environment Dify runs in and refreshes them on every invocation, so nothing long-lived is stored at all.

    The access key path works anywhere — a laptop trial, a single EC2 instance — and that convenience is its whole case. Its cost is a long-lived secret sitting in Dify’s configuration, which you then have to protect, rotate and eventually revoke. Treat it as a starting point for evaluation, not as the production answer.

    On ECS Fargate, prefer the IAM role. Give the Dify services a task role with permission to use Bedrock, and the plugin picks those credentials up automatically — there are no keys in Dify to leak, rotate or forget. This is how the Terraform architecture in this series is wired: the task role is the credential. Whichever path you choose, use separate identities for development and production, so a key or role used in a sandbox cannot reach client data.

    Step 4: Assign models to chat, embedding and rerank

    Assigning models to chat, embedding and rerank

    With the provider saved, assign a default model for each role your workspace uses. The chat model is the visible choice — it is what your applications think with — and several model families are available on Bedrock, each with different strengths, context sizes and prices. Pick per application where it matters rather than forcing one model on everything.

    The embedding model deserves more deliberation than it usually gets. Every document in every knowledge base is embedded with the model you choose here, and changing the embedding model later means re-indexing those knowledge bases to match. Choose it deliberately at the start, and treat a later change as a small migration project, not a settings tweak. Rerank is the optional third role: a rerank model re-orders retrieved passages before they reach the chat model, and it is a cheap quality win for knowledge-base applications once the basics work.

    Step 5: Make a test call before you build anything

    Making a test call to validate the connection

    Before building a real application, run the smallest possible test: a one-prompt chat application using your new provider, or the test facility in the model provider settings if your version offers one. A successful call validates model access, credentials and region in a single stroke. A failure at this stage is cheap; the same failure discovered after you have built a workflow is not.

    Follow it with a second, smaller test that people skip: create a test knowledge base, upload one short document, and confirm indexing completes. That exercises the embedding path end to end — Dify, the plugin, Bedrock and your vector store — and indexing failures otherwise surface days later, in front of users.

    Choosing a region, and cross-region inference

    Region choice and cross-region inference, Japan highlighted

    Your Bedrock region does not have to be the region Dify runs in, but it usually should be: every prompt crosses between them, and distance adds latency to every call. The stronger forces are availability and residency. As noted above, the model catalogue differs by region, so the region decision and the model decision are really one decision — make them together, and write the outcome down, because changing region later changes the model identifiers your applications reference.

    Bedrock also offers cross-region inference profiles, which route a request across several regions behind one identifier to improve throughput and availability. For Japanese client work the important variant is the Japan inference profile, which keeps routing within Japan. If a client’s data may not leave the country, that profile is how you use Bedrock’s managed routing without giving up residency — confirm the profile covers the models you enabled before you rely on it.

    Least-privilege IAM, in practice

    Least-privilege IAM: only the keys you need

    Whichever identity you use — IAM user for keys, task role on Fargate — it needs permission to invoke the models you enabled, in the regions you use, and nothing else. It does not need administrator access, it does not need other AWS services, and it does not need models you have not enabled. Scope the policy to those models, and widen it deliberately, one model at a time, as you enable more.

    Two habits make this sustainable. First, keep development and production identities separate, so experiments never hold production permissions. Second, review the policy whenever you enable a new model or region; permission drift in both directions — too broad, and silently stale — tends to accumulate exactly at those moments.

    What it costs

    Pay-per-token cost of Bedrock models

    Bedrock is pay-per-token: you pay for input and output tokens on language models, and for input tokens on embedding, with no hourly charge for the connection itself and no fee for the Dify plugin. The practical consequence is the one noted in the flagship architecture guide: for a busy team, model usage will exceed the infrastructure bill. The Dify platform might cost the price of a team lunch per month; the models it calls are the real spend.

    Budget accordingly. Put a billing alarm on the AWS account, watch usage per application once you have real traffic, and remember that embedding a large knowledge base is a one-off token cost that can surprise you if you index first and count later.

    Troubleshooting

    Troubleshooting the Bedrock connection

    The model does not appear in Dify. Check, in order: the plugin is installed; the credentials validate; and model access is enabled for that model in the region configured in the provider. Most cases are the third one, in a different region than the one you checked.

    Access denied when the model is called. The identity lacks permission to invoke that model, or access is still pending. Compare the model and region in the error against the console’s model access page, then against your IAM policy’s scope.

    A model is enabled but invocation asks for an inference profile. Some models can only be invoked through a cross-region inference profile rather than by their bare model ID. Select the profile — for Japan-residency requirements, the Japan profile — in place of the direct model where the plugin offers the choice.

    It works in the Bedrock playground but not in Dify. The playground uses your console identity; Dify uses the credentials or role you configured. The two are different identities, possibly in different accounts — check the Dify-side identity first.

    Summary

    Bedrock connected and glowing steadily

    Connect in this order and the pieces stay separable: choose a region, enable model access there, install the official plugin, authenticate with an IAM role wherever Dify runs on AWS (task role on Fargate, keys only for trials), assign chat, embedding and rerank models deliberately, and test both a chat call and a document index before building anything real. Do that, and Bedrock becomes the least interesting part of your Dify stack — which is exactly what infrastructure should be.

    If your Dify is not on AWS yet, start with Self-Host Dify on AWS with Terraform. A companion checklist for upgrading Dify in production is in preparation.

  • What Dify on AWS Actually Costs: Three Architectures Compared

    What Dify on AWS Actually Costs: Three Architectures Compared

    “How much does it cost to run Dify on AWS?” has no single answer, because Dify on AWS is not one architecture. The same application runs on a single virtual server for the price of a streaming subscription, or as a managed, highly available platform for roughly ten times that. This article prices the three setups I actually recommend to people, side by side, so you can choose with your eyes open.

    Every figure below is an estimate for the Tokyo region (ap-northeast-1) as of December 2026, based on public AWS list prices, and labelled as an estimate on purpose: prices change, discounts and free tiers vary, and your usage will differ. Verify the current numbers on the official AWS pricing pages before you budget. Model API usage is excluded from every total here — it is billed per token by Bedrock or your chosen provider, and for a busy team it will exceed the infrastructure bill. That is normal, and it is the same for all three setups.

    The three setups at a glance

    The three architectures side by side
    1. All-in-one EC22. Lean containers3. Fargate production
    ShapeOne EC2 instance, Docker ComposeSmall ECS Fargate tasks + Aurora Serverless v2ECS Fargate + Aurora + ElastiCache, Terraform-managed
    Infrastructure estimateUSD 25–50 / monthUSD 70–115 / monthUSD 120–200 / month
    AvailabilitySingle host; downtime on failure or patchingManaged database; tasks restart automaticallyManaged data tier, rolling deploys, multi-service scaling
    Operating effortAll yours: patching, backups, upgradesLow to moderateLow; infrastructure as code
    Best forPersonal use, small teams, trialsSmall production services on a budgetClient-facing and team-critical deployments

    The rest of this article explains what is inside each number, what drives it up, and where the traps are. The pattern to notice: the differences are rarely the compute. They are the always-on managed services around it.

    Setup 1: all-in-one EC2

    All-in-one EC2: everything on one instance

    One EC2 instance meeting Dify’s documented minimum (at least 2 cores and 4 GiB of RAM; 8 GiB is more comfortable) runs the entire Compose stack — application, PostgreSQL, Redis and vector store on one host and one disk. The estimated USD 25–50 per month covers the instance and its SSD storage in the Tokyo region; there is no load balancer, no NAT gateway and no managed database adding fixed charges.

    This is the cheapest way to keep Dify running continuously, and the estimate is genuinely achievable — as long as you respect what the price buys. One host means one point of failure, backups and patching are your job, and scaling means a maintenance window and a bigger box. My step-by-step guide to this setup (in preparation) covers the hardening that makes it production-viable: closed security groups, HTTPS, replaced default secrets and tested backups.

    Setup 2: lean containers

    Lean containers with a managed database

    The middle option keeps the application in containers and moves only the database to a managed service. Dify’s services run as small ECS Fargate tasks at modest CPU and memory settings, and Aurora PostgreSQL Serverless v2 holds the data; Redis and the vector store stay as containers, and the design deliberately omits the NAT gateway — tasks run with public IPs in public subnets, or reach AWS services through VPC endpoints instead.

    The estimated USD 70–115 per month breaks down roughly as: Aurora Serverless v2 at its 0.5 ACU minimum, an estimated USD 44–55 (Tokyo prices ACU-hours higher than US regions — USD 0.15 versus USD 0.12 per ACU-hour); the small Fargate tasks making up most of the remainder; and no NAT gateway charge, which alone saves an estimated USD 32 or more per month against the full production design. The honest trade-offs: tasks in public subnets need careful security-group discipline, some AWS services still require internet egress, and a load balancer — if you add one for HTTPS convenience — adds an estimated USD 16–25 per month and pushes you toward the top of the range.

    Choose this tier when a real service depends on Dify but the budget is firm. You get a managed, backed-up database and self-healing containers, and you accept a less standard network design in exchange for deleting the fixed charges.

    Setup 3: the Fargate production architecture

    The full Fargate production architecture

    The third setup is the architecture from my guide to self-hosting Dify on AWS with Terraform: every Dify service as its own Fargate service, Aurora PostgreSQL Serverless v2 for data, ElastiCache for Redis, S3 for files, an Application Load Balancer in front, and secrets in Secrets Manager. Its always-on floor is an estimated USD 120–200 per month before any real traffic.

    The components explain the floor: Aurora at its 0.5 ACU minimum is an estimated USD 44–55 of it, the ALB an estimated USD 16–25, one NAT gateway an estimated USD 32 plus data processing, ElastiCache’s smallest node roughly USD 12–25, and the minimum-size Fargate services (API, worker and web running continuously) the remainder. Nothing in that list is waste — each line buys backups, failover or a deploy that does not take the service down. You are paying, roughly, the price of one good team lunch per month to not be your own database administrator, patcher and backup system.

    What actually drives the bill

    The fixed charges that drive the bill

    Four fixed charges decide which tier you land in, and none of them is the Dify application itself. The NAT gateway is the classic surprise: it bills by the hour whether or not traffic flows, so a design with one per availability zone multiplies a charge most small deployments can reduce to one — or design away entirely, as the lean setup does. The load balancer is the second fixed line, justified by HTTPS termination and rolling deploys, optional only in the leanest designs.

    Aurora Serverless v2’s minimum capacity is the third: at 0.5 ACU the database has an hourly floor even when idle, and Tokyo’s per-ACU-hour price is higher than US regions’. The fourth driver is not fixed at all — it is model usage. Every chat response, embedding and rerank is billed per token by your model provider, and an active team’s model bill routinely passes its infrastructure bill. Budget for the two separately, and put alarms on both.

    Cost traps that surprise people

    Cost traps: forgotten stacks and quiet charges

    The first trap is leaving test deployments running. A forgotten Fargate stack or EC2 instance bills quietly for months; tag everything, and delete trials with the same Terraform destroy or console pass that created them. The second is data transfer and NAT data processing on a busy indexing workload — small per gigabyte, but knowledge-base ingestion is exactly the workload that moves gigabytes.

    The third trap is assuming the minimum configuration stays the minimum. Aurora scales up under load and bills for the capacity used; worker tasks scale with indexing queues; storage grows with every uploaded document. The estimates here are floors for quiet deployments, and a popular deployment should expect to sit above them. Set a billing alarm at the level that would surprise you, not the level that would bankrupt you — you want the email while the number is still interesting, not catastrophic.

    Which one should you choose?

    Three paths to three architectures

    Choose EC2 if the audience is you and a few teammates, downtime is an inconvenience rather than an incident, and the budget matters more than the operating time. Choose lean containers if a service depends on Dify daily, the database is the part you least want to operate yourself, and you can accept a less conventional network layout to keep fixed costs down. Choose the full Fargate architecture if clients or a whole team depend on it, if you need deploys without downtime, or if your time is worth more than the difference — which, at these numbers, it usually is.

    And in all three cases, remember the excluded line: pick your model provider and estimate token usage separately. A guide to connecting Dify to Amazon Bedrock as the model provider is coming in this series (in preparation), including the region and pricing considerations on the AWS side.

    Summary

    Comparing the three monthly costs

    Dify on AWS costs an estimated USD 25–50 per month on a single EC2 instance, USD 70–115 as lean containers with a managed database, and USD 120–200 as the full Fargate production architecture — Tokyo region, December 2026, infrastructure only, every figure an estimate to verify against current AWS pricing. The spread is not about the application; it is about how much availability, automation and operational relief you buy around it. Decide which of those you actually need, and the right tier chooses itself.

    Coming next in this series (in preparation): Dify on EC2 with Docker Compose — the cheapest production-viable setup; and a guide to connecting Dify to Amazon Bedrock as your model provider.

  • Dify on EC2 with Docker Compose: The Cheapest Production-Viable Setup

    Dify on EC2 with Docker Compose: The Cheapest Production-Viable Setup

    Not every Dify deployment needs load balancers, managed databases and a Terraform repository. If you are running Dify for yourself or a small team, the cheapest setup that is still honest to call “production” is a single EC2 instance running the official Docker Compose stack — hardened, backed up, and served over HTTPS. This guide walks through that setup and is clear about where its limits are.

    I run Dify on AWS for client work in Japan, and I still keep a personal instance on EC2. It costs less per month than the managed architecture in my ECS Fargate guide, and for a handful of users the difference in reliability does not matter. What does matter is doing the small number of things that separate a demo from a deployment: replacing the default secrets, closing the network, and having backups you have actually tested.

    A note on versions: this guide follows the official Dify documentation as of December 2026. The Compose deployment requires Docker Compose 2.35.0 or later, and the documented minimum hardware is 2 CPU cores and 4 GiB of RAM. Dify releases move quickly, so check the current documentation and the files under docker/ in the Dify repository before you deploy.

    What you will have at the end

    The finished single-instance Dify setup
    • One EC2 instance running the full Dify Compose stack (API, worker, web, PostgreSQL, Redis, vector store and the rest) behind a reverse proxy
    • HTTPS on your own domain, with only ports 80 and 443 reachable from the internet
    • Every bundled default secret replaced with a real one
    • Automated backups: EBS snapshots for the instance and a scheduled database dump you can restore from
    • A clear picture of what this setup cannot do, and when to move off it

    Who this setup is for

    Who the EC2 setup suits: solo developers and small teams

    This is the right shape for a personal instance, a small internal tool for a team of two to ten people, or a serious evaluation you expect to run for months. Traffic is modest, uptime expectations are human (“fix it tomorrow” is acceptable), and one person operates everything. In that world, a single well-kept instance beats a distributed system you have to babysit.

    It is the wrong shape for a client-facing service with an uptime promise, for heavy document indexing, or for anything where an hour of downtime becomes a business problem. A single instance is a single point of failure, and no amount of hardening changes that. If that is your situation, skip ahead to the ECS Fargate architecture instead of growing this one past its limits.

    Choosing the instance

    Three instance sizes, the middle one recommended

    Start from the documented minimum: at least 2 cores and 4 GiB of RAM. That minimum does run Dify, but the Compose stack starts well over a dozen containers, and document indexing plus a code sandbox compete for the same memory. In practice, treat 4 GiB as the floor for a trial and 8 GiB as the comfortable size for an instance you intend to keep.

    For storage, a general-purpose SSD volume in the 30–50 GB range is a sensible starting point for the operating system, the Docker images and the bundled databases. Knowledge-base documents and uploads live on this disk in the default Compose configuration, so size it for your content, not just the software. If the knowledge base grows large, that growth is one of the signals to move storage — and eventually the whole deployment — to managed services.

    On cost: a single instance of this size, with its storage, is an estimated USD 25–50 per month in the Tokyo region as of December 2026. Treat that as a planning estimate, not a quote — check the current EC2 pricing page for your instance type and region before you budget. Model API usage, if you call Bedrock or another provider, is billed separately and can exceed the instance cost for a busy deployment.

    Locking down the network

    A firewall in front of the server with only web ports open

    The security group is your firewall, and the rule is simple: the internet may reach ports 80 and 443, and nothing else. Port 80 exists so the reverse proxy can redirect to HTTPS and answer certificate challenges; all real traffic belongs on 443. The database, Redis and every other container port stay closed — the Compose stack’s data services have no reason to be reachable from outside the host.

    SSH needs the same discipline. Restrict port 22 to your own IP address, or better, avoid opening it at all and use AWS Systems Manager Session Manager to reach the instance through the console or CLI. Either way, “open to the world for convenience” is how small instances get compromised, and a Dify host holds your model provider keys.

    One more network note: Dify’s first-run setup screen creates the initial administrator account, and until you complete it, anyone who can reach the address can claim it. Do the initial setup immediately after the stack starts, before you announce the address to anyone — or keep the security group closed to your IP only until the admin account exists.

    Installing Dify with Docker Compose

    Installing Dify from its Docker Compose stack

    The deployment itself follows the official quick start. Install Docker Engine and Docker Compose (2.35.0 or later) on the instance, clone the Dify repository, and work in its docker/ directory. Before starting anything, copy the example environment file to .env and work through the secrets checklist in the next section — the order matters, because the database initialises with the password it finds on first boot.

    Start the stack with docker compose up -d, using the default profile unless you know you need the optional services. Then open the install page at http://your-domain/install (through the proxy, this becomes your HTTPS address) and create the administrator account. After that, sign in and confirm the console loads, the worker is running, and a small test workflow executes.

    Two operational habits are worth forming on day one. First, pin your deployment: note the Dify version you installed, and upgrade deliberately rather than pulling the latest images by reflex. Second, keep a copy of your .env file somewhere safe and private — losing it means losing the values that encrypt and sign parts of your deployment’s data.

    HTTPS with a reverse proxy

    HTTPS termination at a reverse proxy

    Dify’s Compose stack serves plain HTTP through its bundled nginx on port 80 by default (the EXPOSE_NGINX_PORT setting controls the published port). For a real deployment, put a reverse proxy in front that terminates TLS: a common pattern on a single instance is a lightweight proxy with automatic Let’s Encrypt certificates, or nginx configured with certificates you manage. The proxy listens on 443, forwards to the Compose nginx, and redirects port 80 traffic to HTTPS.

    Whichever proxy you choose, set Dify’s console, service API and web app base URLs to your HTTPS domain afterwards. If you skip this, share links, file URLs and OAuth callbacks will quietly point at the wrong address or scheme. Test one full round trip — sign in, upload a file, open a published app link — before calling the setup done.

    The secrets checklist

    The default secrets that must be replaced

    The Compose files ship with development credentials so the demo starts in one command, and every one of them is public knowledge. Replacing all of them is the single most important step in this guide. The official documentation lists what to change in docker/.env before other people can reach the deployment:

    • Database and Redis: set DB_PASSWORD and REDIS_PASSWORD to strong, unique values.
    • Code sandbox: set SANDBOX_API_KEY and CODE_EXECUTION_API_KEY to the same strong secret.
    • Weaviate: set WEAVIATE_API_KEY to a strong secret listed in WEAVIATE_AUTHENTICATION_APIKEY_ALLOWED_KEYS, and set WEAVIATE_AUTHENTICATION_ANONYMOUS_ACCESS_ENABLED=false so the vector store requires authentication.
    • Plugin daemon: set PLUGIN_DAEMON_KEY and PLUGIN_DIFY_INNER_API_KEY to separate strong values.
    • Agent tokens: replace the bundled agent API token and generate the agent server secret key in its required format, keeping the local sandbox auth token generated at startup.

    Apply changes by restarting the stack so the new values take effect. One exception deserves care: the database password. Once the database has been initialised, change the password on the database server first and only then update DB_PASSWORD to match — changing only the .env file locks the application out of its own database.

    Also note the default stack’s quiet strength: it publishes no host ports for the database, Redis, the sandbox or Weaviate. Keep it that way. Restrict access to those services on the private network too, not just at the security group.

    Backups that actually exist

    Snapshots and database backups with a restore path

    Two layers cover a single-instance deployment. EBS snapshots — scheduled automatically with AWS Backup or a lifecycle policy — capture the whole volume, including Docker’s data. Separately, schedule a regular pg_dump of the Dify database to a file that is copied off the instance, for example to an S3 bucket, so a lost instance does not take the only copy with it.

    The rule from my managed-architecture guide applies unchanged: a backup you have never restored is a hope, not a backup. In the first month, restore a snapshot to a throwaway instance (or at least restore the database dump into a scratch container) and confirm Dify starts and your apps are present. The twenty minutes that takes is the cheapest insurance in this entire setup.

    The honest limits

    The honest limits of a single instance

    Availability is the obvious one: patching, a failed upgrade or an instance problem means downtime, because there is nothing else to serve traffic. Scaling is the second: when indexing or concurrent users outgrow the box, your only move is a bigger instance and a maintenance window. Neither is a defect — they are the price of the cheapest tier, and they are acceptable exactly as long as the audience is small and forgiving.

    Upgrades are manual work here, too. Read the target release’s upgrade guide first, and run every Compose command with the same project name and options as your original deployment, so the named volumes stay attached and the same configuration is loaded. A full walkthrough of upgrading safely is coming in a companion article (in preparation); the short version is: back up, read the guide, then upgrade — never in another order.

    When to graduate to ECS Fargate

    Graduating from one instance to orchestrated containers

    Move when any of these become true: the instance serves people outside your own team, downtime starts costing money or trust, indexing load makes the console sluggish, or you are avoiding upgrades because they feel risky. Those are signs the operational work has outgrown the savings. My guide to self-hosting Dify on AWS with Terraform builds the managed version — ECS Fargate for the services, Aurora PostgreSQL and ElastiCache for the data, S3 for files — and most of what you learned here transfers: the secrets discipline, the settings that matter, and the backup habit.

    Summary

    A calm, low-cost Dify instance at sunrise

    A single EC2 instance running the official Compose stack is the cheapest Dify deployment worth calling production: 2 cores and 4 GiB at minimum, a security group that exposes only 80 and 443, a reverse proxy for HTTPS, every default secret replaced, and snapshots plus database dumps you have test-restored. It will not scale and it will not survive its own host — and for a personal instance or a small team, it does not need to. When it does, the Fargate architecture is the next step, not a bigger box.

    Coming next in this series (in preparation): What Dify on AWS Actually Costs, a three-architecture comparison; and a guide to connecting Dify to Amazon Bedrock as your model provider.

  • SES Margins and Return Rates: How Much of Your Billing Rate You Actually Keep

    SES Margins and Return Rates: How Much of Your Billing Rate You Actually Keep

    Two engineers do the same work on the same project. One keeps almost everything the client pays; the other loses a fifth of it on the way through — and may never find out. The difference is not the work. It is the contract chain between the client and the engineer, and in Japan that chain has a name (SES), a standard shape, and a number attached to it: the margin.

    This article explains how the margin works, what a fair one looks like, and the questions that reveal yours before you sign. I work in this market as a freelance engineer in Japan, and everything here is the version I wish someone had handed me before my first contract.

    First, the three numbers you need to keep separate

    Three jars with different amounts of coins: billing, margin and pay

    Confusion starts because three different figures all get called “the rate”:

    • The billing rate — what the client pays per month for you. This is the number at the top of the chain.
    • Your rate — what you actually receive per month, after every intermediary has taken its part.
    • The return rate — your rate divided by the billing rate, expressed as a percentage. If the client is billed 1,000,000 yen and you receive 850,000 yen, the return rate is 85% and the total margin taken along the chain is 15%.

    When an agent quotes you a project, ask which of these numbers they are quoting. Good agents quote your rate and will tell you the billing rate if you ask. The ones who will not answer either question have told you something important anyway.

    Where the margin goes: the chain

    The SES chain from client company through intermediaries to the engineer

    In a direct freelance arrangement the chain has two links: client → agent → you. The agent finds the project, handles the contract and invoicing, and takes a margin for it — commonly in the range of 10–20% of the billing rate for a straightforward placement, with the rest returning to you.

    SES arrangements add links. A typical multi-layer chain looks like this: the client contracts with a prime SIer; the SIer, short of engineers, contracts with an SES company; the SES company supplies an engineer — who may be its employee, or a freelancer it has contracted in turn. Each company in the chain takes a margin for coordination, risk and profit. Three layers at 10% each do not sound dramatic until you do the arithmetic: 1,000,000 yen billed becomes about 900,000, then 810,000, then roughly 730,000 yen at the end of the chain — a return rate near 73%, before anyone has done anything dishonest. The layers are the cost.

    This is also why two offers for “the same project” can differ by 150,000 yen a month. They are the same project, seen from different positions in the chain.

    What the margin actually pays for

    What the margin pays for: sales, administration and support

    A margin is not automatically exploitation, and treating it as pure loss will make you a worse negotiator. A good agent earns theirs: they hold the client relationship, they carry the payment risk (you are paid on schedule even if the client’s payment is late), they handle the contract paperwork and the consumption-tax invoicing, and they find your next project before this one ends. For a freelancer new to the Japanese market, that bundle is worth real money.

    What you are paying for, in other words, is distribution and administration. The question is never “is there a margin?” — there always is. The questions are how large it is, how many hands it passes through, and whether you are told.

    Return rates: what is normal, what is a warning

    A gauge showing normal and warning return-rate zones

    Based on published agent policies and the offers circulating in the current market (checked November 2026):

    • 85–95% return — a clean, direct agent placement. Several Japanese freelance agents now publish their margin or return-rate policy openly; the competitive end of the market advertises margins around 10% or less, and some specialise in high return rates as their selling point.
    • 75–85% return — common where an SIer sits between the agent and the client, or where the agent provides more (on-site support, guaranteed payment terms, benefits-like services for sole proprietors).
    • Below 75% return — a long chain, or a chain nobody wants to explain. Not automatically a reason to refuse — the absolute yen figure is what you live on — but it is a reason to ask questions, and to compare the same skills against a direct offer.

    Judge the number you receive, not only the percentage. A 78% return on a 1,200,000-yen billing rate (936,000 yen) beats a 92% return on a 900,000-yen billing rate (828,000 yen). Percentages are for spotting structure; yen is for paying rent.

    Five questions to ask before you sign

    Asking an agent five questions before signing
    1. “What is the billing rate for this position?” (Japanese agents hear this question routinely; asking it marks you as experienced, not rude.)
    2. “Who is the contracting party, and who is the client?” If the agent cannot or will not name the layers between you and the end client, assume there are more than they would like you to count.
    3. “Is the contract a quasi-mandate (SES) contract, and where will I work and take direction from?” This decides your legal position and your daily life; it should be stated plainly, in writing.
    4. “When am I paid, and is payment conditional on the client paying you?” The standard worth having is a fixed payment date that does not move with the client’s payment.
    5. “Can the rate be reviewed at renewal?” The answer tells you whether this engagement can grow, or whether your only raise is leaving.

    Write the answers down. In this market, the difference between a good year and a frustrating one is usually decided in these five answers, not in the interview.

    The employee side of the same coin

    Employee salary and freelance income compared on a balance scale

    If you join an SES company as an employee instead of freelancing, the same arithmetic runs in reverse: the company bills the client for you, and your salary is your “return”. Employee return rates are structurally lower — the company carries social insurance, paid leave, bench time between projects and sales staff — but some SES companies now publish a guaranteed return rate (for example, returning a fixed, stated percentage of your billing rate as salary) as a recruiting tool. If you are comparing an SES salary offer against freelancing, compare them on the same basis: annual money in your pocket after tax and insurance, not the headline monthly figure. Our article on becoming a freelance engineer in Japan walks through that calculation from the sole-proprietor side.

    Summary

    An engineer walking a path of coins toward a Tokyo sunrise

    The client pays a billing rate; you receive your rate; the ratio between them is the return rate, and the gap is the margin — the price of the chain between you and the work. Short chains and published margins return 85–95%; long SES chains return less, layer by layer. Ask for the billing rate, count the layers, fix your payment date, and judge offers in yen. Do that, and the margin stops being something that happens to you and becomes a number you negotiate.

    Next in this series: Working with Japanese Freelance Agents — how they work, what to negotiate, and the red flags. The market context for everything here is in Freelance Engineer Rates in Japan (2026).

  • Self-Host Dify on AWS with Terraform: ECS Fargate, Aurora PostgreSQL and ElastiCache

    Self-Host Dify on AWS with Terraform: ECS Fargate, Aurora PostgreSQL and ElastiCache

    Dify’s own quick start is one command: clone the repository, run Docker Compose, open your browser. That gets you a demo in ten minutes — and a stack you cannot safely leave running for a real team. The Compose file runs about fifteen containers on one host, including PostgreSQL, Redis and the vector database, all with bundled default secrets, all gone if the host dies.

    This guide builds the version I would actually hand to a client: Dify’s containers on ECS Fargate, its data in managed services (Aurora PostgreSQL, ElastiCache for Redis, S3 for files), everything defined in Terraform, with the decisions — and the bill — explained. I build and operate Dify on AWS for client work in Japan; this is the architecture I start from, and the notes include the parts that only show up after you have run it for a while.

    A note on versions: Dify moves fast. This guide is written against the Dify 1.x line (the official Compose file referenced image tag 1.20.0 when this was written, in December 2026). The architecture does not depend on the minor version; the environment settings occasionally do, so check the current files under docker/envs/ in the Dify repository before you deploy — recent versions reorganised them.

    What you will have at the end

    Laptop showing the finished Dify web console and dashboard
    • Dify’s web console and API behind an Application Load Balancer with HTTPS, on your own domain
    • The Dify services (api, api_websocket, worker, worker_beat, web, plugin_daemon, sandbox) running as Fargate tasks you can scale independently
    • Aurora PostgreSQL Serverless v2 holding Dify’s application data, with automated backups and point-in-time recovery
    • ElastiCache for Redis as the Celery broker and cache
    • Uploaded files and knowledge-base documents in S3 instead of a container filesystem
    • All secrets in AWS Secrets Manager, none in the repository
    • The whole thing reproducible from Terraform: one apply to build, one destroy to remove

    Why ECS Fargate (and when not to)

    Diagram comparing AWS container options: EC2, ECS Fargate and EKS

    Three container options are realistic on AWS, and the honest comparison is short.

    EC2 with Docker Compose is the cheapest way to run Dify and the closest to the official guide. It is the right answer for a personal instance or a trial. Its limits are operational: one host is one point of failure, patching and backups are yours, and scaling means a bigger box.

    ECS Fargate is the middle path this guide takes. No hosts to patch, each Dify service scales on its own, rolling deploys are built in, and the data tier moves to managed services where AWS handles backups and failover. You pay more than for a single EC2 instance; you buy back the operational work.

    EKS only earns its complexity if your organisation already runs Kubernetes and wants Dify inside it. If you have to ask whether you need EKS for Dify, you do not.

    The architecture, service by service

    Dify is not one application. Its Compose stack has three groups, and the AWS design follows from keeping them straight.

    Diagram of the Dify on AWS architecture: an Application Load Balancer in front of ECS Fargate services (web, api, api_websocket, worker, worker_beat, plugin_daemon, sandbox, Weaviate), backed by Aurora PostgreSQL, ElastiCache Redis and S3, with Secrets Manager, CloudWatch and Terraform as platform services.

    Stateless Dify services — these become Fargate services, one task definition per role, sharing the same images as the Compose stack: api (the backend and console API), api_websocket (live workflow co-editing; an optional service enabled by the “collaboration” Compose profile), worker (Celery: document indexing, workflow jobs), worker_beat (the scheduler), web (the Next.js frontend), plugin_daemon (model and tool plugins), and sandbox (isolated execution for Code nodes). The sandbox deserves one caution: it runs user code, so it belongs in its own service with no route to anything except the API that calls it — do not co-locate it with the API task to save money.

    Stateful dependencies — these leave the containers entirely. PostgreSQL becomes Aurora PostgreSQL Serverless v2 (Dify points at it with its normal DB settings). Redis becomes ElastiCache. File storage switches to S3 by setting Dify’s storage type to S3, so uploads and dataset files survive task replacement. The bundled Weaviate is the one dependency I usually keep as a container at first — a small dedicated Fargate service with EFS for its data — and move to a managed or external vector store only when the knowledge base grows; Dify also supports external vector databases through its VECTOR_STORE setting if you already run one.

    Edge and platform — an ALB terminates HTTPS (ACM certificate) and routes console traffic to web and API paths to api. nginx, which fronts everything in the Compose stack, is no longer needed as a separate container; the ALB does its job. Secrets (database password, Redis auth, Dify’s SECRET_KEY, the sandbox and plugin-daemon keys) live in Secrets Manager and are injected into tasks. Logs go to CloudWatch Logs, one log group per service — when a workflow fails at 2 a.m., this is where you will live.

    Networking follows the standard shape: public subnets only for the ALB, private subnets for tasks and data, and VPC endpoints (or a NAT gateway) for tasks to reach ECR, S3 and Secrets Manager. Budget note: a NAT gateway in every availability zone is a quiet, fixed monthly cost that surprises people; a single NAT for a small deployment, plus gateway endpoints for S3 and DynamoDB (which are free), is a reasonable economy — with the availability trade-off stated, not hidden.

    The Terraform layout

    Cloud infrastructure being built from Terraform modules

    Keep it boring. One root module per environment, composed from small modules you will reuse for the next service you host:

    • network: VPC, subnets, endpoints, security groups (one per tier, chained by reference, no open database ports)
    • data: Aurora cluster (Serverless v2 scaling block, minimum 0.5 ACU), ElastiCache replication group, S3 bucket with versioning and encryption, EFS for Weaviate
    • platform: ECS cluster, task definitions and services per Dify role, ALB and listeners, ACM certificate, Secrets Manager entries, CloudWatch log groups and alarms
    • state: an S3 backend with DynamoDB locking, created once by hand (or by a bootstrap stack) before the first apply

    Two practices matter more than the module structure. First, pin everything: the Terraform AWS provider, and the Dify image tags — never deploy latest for a platform whose upgrades occasionally include manual data steps (Dify’s 1.17 line, for example, required a staged Weaviate upgrade; a pinned tag is what turns that from an incident into a planned change). Second, treat the Dify environment variables as code: define them in the task definitions from variables and secrets, so a diff shows exactly what a deploy changes.

    The Dify settings that actually matter

    Dify settings panel with a key and configuration toggles

    Most of Dify’s .env transfers directly to task environment variables. The ones people get wrong:

    • SECRET_KEY: generate a real random value, store it in Secrets Manager, and never change it casually — it signs sessions and encrypts stored credentials.
    • Database and Redis settings: point them at Aurora and ElastiCache endpoints, with TLS where the service requires it, and use a dedicated database and user for Dify.
    • Storage: switch the storage backend from local disk to S3 (the storage settings live in the env files) and give the task role permission to exactly one bucket. Leaving local storage on Fargate means uploads vanish on the next deploy.
    • Sandbox keys: the sandbox API key and the code-execution endpoint key must match between the api and sandbox services, and neither may be the bundled default. The same applies to the plugin daemon key. Every default secret in the Compose files is publicly known; replacing all of them is the single most important security step in this whole guide.
    • Web and console URLs: set Dify’s console, service API and web app base URLs to your HTTPS domain, or share links and OAuth callbacks will quietly point at the wrong place.

    Deploying, in order

    Stairs leading up to a cloud, showing the deployment steps in order
    1. Apply the network and data modules first, and note the endpoints Terraform outputs.
    2. Set the secret values in Secrets Manager (Terraform creates the entries; the values themselves are set out of band so they never touch state in plain text).
    3. Apply the platform module. The first run pulls images and starts services; the api service runs database migrations on boot.
    4. Watch the api service’s logs until migrations complete, then open the ALB address: Dify’s setup screen creates the first administrator account. Create it immediately — until you do, anyone who can reach the address can.
    5. Point your domain’s DNS at the ALB, confirm HTTPS, and only then open the security groups to your team’s addresses (or your VPN) if the console is not meant to be public.

    First-boot checks that catch most problems: the worker service’s logs show it connecting to Redis and registering tasks; uploading a small document to a new knowledge base completes indexing (this exercises worker, S3, the vector store and your model provider key in one action); and a test workflow with a Code node returns a result (this exercises the sandbox path).

    What it costs

    Balance scale weighing cloud infrastructure against coins

    Estimates, not quotes — AWS prices change and vary by region, so treat these as planning figures for a small production deployment in a major region (US East or Tokyo), checked against public AWS pricing in late 2026, and re-check the official pricing pages before you budget.

    The always-on floor is roughly USD 120–200 per month before any real traffic: Aurora Serverless v2 at its 0.5 ACU minimum is about USD 44–55 of that (Tokyo is priced higher per ACU-hour than US regions), the ALB about USD 16–25, one NAT gateway about USD 32 plus data processing, ElastiCache’s smallest cache node roughly USD 12–25, and the Fargate services at minimum size (api, worker and web running continuously at small CPU/memory settings) the remainder. Model API usage (Bedrock or otherwise) is billed separately and, for a busy team, will exceed the infrastructure bill — that is normal, and a later article in this series will compare this architecture’s cost side by side with the EC2 and minimum setups.

    The honest summary: you pay roughly the price of one good team lunch per month to not be your own database administrator, patcher and backup system. For a client-facing deployment that trade is easy; for a personal playground it is not — a single EC2 instance is the better fit.

    Running it: the short list

    Monitoring gauges with a heartbeat line for running Dify
    • Backups: Aurora’s automated backups with point-in-time recovery cover the database; the S3 bucket’s versioning covers files. Test a restore once, in the first month, or you do not have backups — you have a hope.
    • Alarms: alarm on worker queue depth (indexing silently backing up is the most common Dify production complaint), api 5xx at the ALB, and Aurora CPU/ACU saturation.
    • Scaling: worker is the service that scales with document and workflow load; api scales with console and API traffic; web barely moves. Scale them independently — that was the point of splitting them.
    • Upgrades: read the release notes, snapshot first, upgrade in a maintenance window, and check whether the vector store has its own migration step before you touch the Dify version. A later article in this series will set out the full procedure as a production upgrade checklist.

    Failure modes worth knowing in advance

    Magnifying glass inspecting a failed link in a service chain
    • Indexing stuck at “indexing” forever: almost always the worker cannot reach Redis, the vector store, or the model provider — in that order. Check worker logs before touching anything else.
    • Code nodes timing out: the api cannot reach the sandbox service, or the sandbox keys do not match between services.
    • Sessions dropping after a deploy: SECRET_KEY differs between api tasks or changed between versions.
    • Uploads disappearing: storage is still on local disk in a task somewhere — check the storage setting on every service that writes files, not just api.

    Summary

    Sunrise over the cloud setup with a checkmark

    Run Dify’s services as services, and its data as managed data. ECS Fargate for the containers, Aurora PostgreSQL and ElastiCache for the state Dify cannot afford to lose, S3 for files, Secrets Manager for the keys, Terraform for all of it — pinned, diffed and reproducible. The Compose stack is a brilliant demo and a fine personal setup; this is what it grows into when a team depends on it.

    Coming next in this series (in preparation): Dify on EC2 with Docker Compose — the cheapest production-viable setup; What Dify on AWS Actually Costs, a three-architecture comparison; and a guide to connecting Dify to Amazon Bedrock as your model provider.

  • Freelance Engineer Rates in Japan (2026): Monthly Rates by Skill and Experience

    Freelance Engineer Rates in Japan (2026): Monthly Rates by Skill and Experience

    “What is a normal monthly rate for a freelance engineer in Japan?” is the question every engineer asks before entering this market — and the hardest one to answer from outside, because Japanese rates are quoted in a unit most countries do not use, published mainly in Japanese, and split by a margin system most guides never mention.

    This article gives you the 2026 numbers with their sources and dates attached, explains how to read them, and shows you the adjustments — experience, cloud and AI skills, Japanese ability, and the agent’s margin — that move a real offer up or down. I work in this market as a freelance AWS and generative AI engineer, and I have added my own reading of where the published averages sit against the offers that actually circulate.

    How to read a Japanese freelance rate

    Magnifying glass over freelance rate documents and a grid

    Four conventions first, because without them the table below will mislead you.

    Rates are per person per month. Freelance engineers in Japan are billed monthly for one engineer working a standard month — usually defined as a range of business days or hours (for example 140–180 hours). Work far outside the agreed range and the fee is adjusted by a per-day or per-hour unit price written into the contract.

    Rates are quoted tax-exclusive. The figure is before consumption tax, and before your own income tax, pension and health insurance, which as a sole proprietor are your responsibility.

    The quoted rate is not always what the engineer receives. If you work through an agent, the client may be billed more than the rate you agreed; the difference is the agent’s margin. Some agents quote you the post-margin rate from the start, which is the cleaner arrangement. The rates in this article are the rates agreed with the engineer — the level at which agents advertise projects and engineers sign.

    Tokyo sets the market. Most freelance projects, and nearly all published statistics, are for the Tokyo metropolitan area. Regional rates run lower, fully remote projects are priced against the Tokyo market more often than they used to be.

    The 2026 rate table

    Three-dimensional bar chart of stacked cubes in teal, blue and orange

    The most solid public dataset is from Levtech Freelance, one of Japan’s largest freelance engineer agents, which publishes the average monthly rates of engineers actually placed through it (full-time, five-day engagements, Tokyo area; data published in its 2026 guide, based on placements as of January 2026). Averages hide a range, so read each figure as the middle of a band roughly 150,000–250,000 yen wide.

    RoleAverage monthly rate (JPY)
    IT consultant836,000
    PMO823,000
    PM808,000
    Cloud engineer755,000
    Project leader (PL)744,000
    Frontend engineer727,000
    Server-side engineer683,000
    Network engineer678,000
    Server engineer659,000
    Embedded / control engineer616,000

    By language and skill, the same source gives: Ruby 784,000 / JavaScript 721,000 / Python 714,000 / PHP 681,000 per month on average. The overall average across placed web and application engineers works out at roughly 730,000 yen per month (an average annual income of 8.81 million yen on a twelve-month engagement).

    Experience moves you through the band more than any single technology does. As a working rule from current project listings: engineers with one to three years of experience are typically proposed at 400,000–600,000 yen; mid-level engineers at 600,000–850,000 yen; senior engineers and tech leads at 800,000–1,100,000 yen; and cloud, data and machine-learning specialists at 900,000–1,300,000 yen and above. English-facing agent listings tell the same story from the top end: lead-level AWS infrastructure projects (design and build, IaC) are advertised with guide rates around 1,500,000 yen per month, which is a ceiling for scarce lead roles, not a norm.

    Where AWS and generative AI sit

    Glowing neural network sphere above a cloud with gears, between two server racks

    Cloud is already visible in the table: the cloud engineer average (755,000 yen) sits above the general server-side and frontend averages, and that average blends junior cloud operators with senior architects. In the current market the premium stacks like this:

    • AWS design and build experience (not just operation) is the first step up — projects that include architecture and IaC (Terraform or CloudFormation) are proposed higher than run-and-maintain work with the same years of experience.
    • Generative AI delivery experience — building and operating LLM applications, for example Dify or Bedrock-based systems in production — is the newest premium. There are few engineers in Japan who have shipped these systems for clients, and project rates for AI-related work are advertised at the top of the specialist band.
    • Certifications support the proposal, they do not set the rate. An AWS certification gets your skill sheet read; the rate is set by what you have built. (I hold 11 of the 12 current AWS certifications, and in negotiations they have opened doors — the number was decided by project experience.)

    The adjustments that move a real offer

    Control panel with vertical sliders, a gauge dial and toggle switches

    Japanese ability. Projects whose meetings and design documents run in Japanese can only propose engineers who can work in Japanese. That filter shrinks the candidate pool and supports rates; engineers who cannot work in Japanese are limited to the smaller set of English-friendly projects, which are concentrated in international companies and startups.

    On-site requirements. Fully remote projects draw applicants nationally and price against the Tokyo band. Projects requiring several days a week on site in Tokyo pay for that constraint, especially outside the most common skill sets.

    Contract length and renewal. A six-to-twelve-month engagement with likely renewal is the standard shape. Very short engagements sometimes carry a higher monthly rate; very long ones trade a little rate for stability.

    The margin question. If an agent proposes you at 800,000 yen, the client may be billed 800,000 yen (margin taken elsewhere in the chain), 900,000 yen, or more. You will not always be told. Asking is normal, and agents differ in whether they answer — that difference is worth money over a year, and a later article in this series takes it up in full, on SES margins and return rates.

    How negotiation actually goes

    Two people negotiating at a table with a laptop, in front of a stepped bar chart

    Rates in this market are usually negotiated once, at the start, through the agent — and then adjusted at renewal rather than continuously. The practical pattern:

    1. The agent proposes a project with a rate range, not a single figure.
    2. Your stated desired rate, your skill sheet and the interview decide where in the range you land.
    3. A rate increase is easiest to win at renewal, after you have become load-bearing on the project — a modest increase (30,000–50,000 yen per month) at renewal is a normal ask when the project is going well.
    4. Jumping agents mid-project to chase a rate is uncommon and can burn the client relationship; changing projects is the usual way to reset your rate upward.

    Sources, method and limits

    Stack of documents with a glowing checkmark seal
    • Role and skill averages: Levtech Freelance official guide (2026 edition; placement data as of January 2026), full-time five-day engagements in the Tokyo area, one agent’s placements — not a national census.
    • Experience bands and top-end examples: current public project listings from Japanese and English-facing freelance agents, checked November 2026.
    • This article is updated yearly. Rates are market observations, not a guarantee of what any individual engineer will be offered; your rate will depend on your skills, experience, language ability and the projects open when you look.

    Summary

    Engineer in a hard hat overlooking a city skyline at sunrise

    In 2026, a mid-career freelance engineer in Japan most often signs somewhere between 600,000 and 900,000 yen per month; cloud and AI specialists and lead roles run from 900,000 yen to well past 1,200,000 yen; and the published averages — about 730,000 yen overall, 755,000 yen for cloud engineers — are the middle of the market, not its ceiling. Read every rate with its unit (person-month, tax-exclusive), ask what the client is billed, and treat Japanese ability and shipped AI/cloud experience as the two levers that move your number most.

    Coming next in this series (in preparation): SES Margins and Return Rates — how much of your billing rate you actually keep — and Working with Japanese Freelance Agents.

  • How Japan’s IT Industry Actually Works: SIers, SES and Freelance Agents, Explained by a Japanese Engineer

    How Japan’s IT Industry Actually Works: SIers, SES and Freelance Agents, Explained by a Japanese Engineer

    If you read English guides about working in tech in Japan, you will meet the same few words again and again: SIer, SES, dispatch, freelance agent. Most guides define them in one line each and move on. That is a shame, because these are not vocabulary items. They are the structure that decides who you work for, who actually directs your work, how much of your billing rate reaches you, and which rules protect you when something goes wrong.

    I am a Japanese engineer. I have worked as a company employee inside this structure, and I now work as a freelance engineer through the agent system this article explains. This is the map I wish someone had handed me at the start — written for engineers outside Japan who want to understand the industry they are thinking of entering.

    The one-paragraph map

    Illustration of the layered map of Japan's IT industry

    A large Japanese company that needs a system rarely hires engineers directly to build it. It signs a contract with a large systems integrator — an SIer — which designs the project and takes responsibility for delivery. The SIer does not employ all the engineers it needs, so it passes parts of the work to partner companies, which may pass parts on again. Alongside this contracting chain sits a second labour market: SES companies and freelance agents, which supply individual engineers to work on projects, billed per person per month. If you come to Japan as an engineer, the layer you enter this structure at will shape your daily work, your income, and your career options more than the name of the company on the building.

    SIers: the companies that own the project

    Illustration of a tall SIer tower connected to smaller companies below

    SIer (pronounced roughly “ess-eye-er”) is short for system integrator. The major SIers are large, long-established Japanese IT companies. Their business is to win a contract from an end client — a bank, a manufacturer, a retailer, a government body — and deliver a working system for an agreed price and deadline.

    Two things follow from that business model.

    First, SIers manage projects more than they write code. Their senior staff write proposals, estimates, designs and schedules, and coordinate the companies below them. Hands-on development is often done by partner companies further down the chain.

    Second, the chain is real. A project may involve the end client, the prime SIer that holds the contract (the “prime” or ichiji-uke), a second-tier company (niji-uke), and sometimes a third. Each layer takes a margin for managing the layer below it. This multi-layer subcontracting is the single most criticised feature of the Japanese IT industry, and also the one that explains the most: it is why a project can have a healthy budget at the top and still pay modest rates at the keyboard, and why decisions can take time — several companies sit between the person who writes the code and the person who asked for the system.

    For an engineer entering Japan, SIers matter in two ways. They are stable, large employers that hire foreign engineers, and their projects are where most agent-supplied freelancers ultimately work, even when the freelancer’s contract is with someone else entirely.

    SES: renting engineers by the person-month

    Illustration of rows of engineers lined up for dispatch to client projects

    SES stands for system engineering services. An SES company employs engineers and supplies them to a client’s project under a contract form called a quasi-mandate contract (jun-inin keiyaku). The legal detail matters, so here it is in plain terms:

    • Under a contract for work (ukeoi), the vendor promises a finished deliverable and is responsible if it is not completed.
    • Under a quasi-mandate contract, the engineer promises to do the work properly and diligently — but the deliverable itself is not guaranteed by the supplying company.
    • Under worker dispatch (haken), the engineer is directed by the client company, and a different set of labour rules applies.

    In an SES arrangement, the engineer works at the client’s site or remotely for the client’s project, takes day-to-day technical direction within the project, and is billed per person per month (the unit is often written as a monthly rate for one engineer). The SES company handles the contract, invoicing and the engineer’s employment; the engineer is its employee, not the client’s.

    SES is where a large share of Japan’s engineers actually spend their careers, and it has a mixed reputation that is worth understanding rather than repeating. The weak version of SES is an engineer sent to a site with little support, on a contract whose billing rate the engineer never sees, keeping a modest fraction of it as salary. The stronger version is a company that chooses projects deliberately, is transparent about rates, and invests in its engineers. Both exist, and the difference between them is mostly a matter of how much of your billing rate reaches you — what Japanese engineers call the return rate (kangen-ritsu). I have written about that in detail in a separate article on SES margins and return rates, because it is the number that decides whether an SES job is a fair deal.

    Freelance agents: the market for independent engineers

    Illustration of a freelance agent's office with doors leading to client projects

    Above a certain experience level, many Japanese engineers leave employment and work as sole proprietors (kojin jigyonushi) — independent freelancers. Most of them do not find projects by themselves. They register with freelance agent companies, which match engineers to projects at SIers, SES companies and end clients, and handle the contract and payment in between.

    The flow looks like this:

    1. You register with an agent and list your skills and desired rate.
    2. The agent proposes projects — usually described by role, skills, location, remote policy and a monthly rate range.
    3. You interview with the client side (often the SIer or the project-owning company), usually once or twice.
    4. If it fits, you sign a service contract through the agent, start on the project, and invoice monthly.
    5. The agent takes its margin from the client’s payment and pays you the agreed rate, typically on a fixed payment cycle (payment 30 to 60 days after the work month is common; the exact terms differ by agent and are worth confirming before you sign).

    What surprises engineers from countries with direct contracting cultures is how normal this is. In Japan, the agent is not a fallback for people who cannot find work. Senior engineers with strong skills use agents because that is where the projects are listed, because the agent absorbs the paperwork and credit risk, and because negotiating through an agent is socially easier than negotiating alone in a business culture that avoids direct confrontation over money.

    The agent’s margin is the price of that service, and it varies. Some agents disclose the client billing rate; many do not. Asking what the client is billed — and choosing agents who will answer — is one of the most practical pieces of advice in this whole series, and a later article in this series will cover working with Japanese freelance agents in detail.

    How this differs from contracting in the West

    Illustration of engineers shaking hands and discussing contracting differences

    A few contrasts help the structure come into focus.

    • Direct contracts are rare. In the US or Europe, an experienced contractor often contracts directly with the end client. In Japan, an intermediary — an SIer, an SES company or an agent — is the default, at almost every level.
    • Rates are monthly, not hourly or daily. Freelance billing is overwhelmingly per person per month, tied to a standard number of business days, with adjustments if you work significantly more or fewer days than the agreed range.
    • Interviews are light, paperwork is not. Getting onto a project usually takes one or two interviews, but the contracting, registration and compliance steps around it are formal and document-heavy.
    • Stability is valued over rate maximisation. Long renewals on one project are common and usually seen as a good outcome by all sides, rather than as a lack of ambition.

    None of this makes the Japanese system better or worse in itself. It makes it a system, with rules you can learn — and once you know which layer you are in and how the money flows through it, you can make deliberate choices instead of accidental ones.

    What this means if you want to work in Japan as an engineer

    Illustration of an engineer with a backpack standing before a Tokyo city skyline

    Three practical conclusions follow from the map above.

    First, decide which door you are entering through. A direct hire at an SIer or a product company gives you employment stability and a visa sponsor with a track record. An SES company gives you project variety but makes the return rate the key question. Freelancing through agents pays the most per month but generally requires you to already be living in Japan with a work status that allows it, plus the language and track record to be proposed to clients. (Visa categories and requirements are general public information and change over time; check the official immigration sources for your own case rather than relying on any blog, including this one.)

    Second, learn to ask about the layer. “Who holds the contract with the end client, and where would I sit?” is a normal, professional question in Japan. The answer tells you how many margins stand between the budget and you.

    Third, treat Japanese language ability as a rate factor, not just a communication tool. Much of the project layer — design documents, meetings with the end client, the SIer’s management chain — runs in Japanese. Engineers who can work in Japanese are simply proposable to more projects, and the rate tables in our 2026 freelance rates article show that difference in money terms.

    Glossary

    Illustration of an open book with icons explaining key terms
    • SIer — A system integrator; a company that contracts to deliver a whole system for a client and coordinates the companies that build it.
    • Prime / subcontracting layers — The prime contractor holds the contract with the end client; second- and third-tier companies supply parts of the work under it.
    • SES — System engineering services; supplying employed engineers to projects under a quasi-mandate contract, billed per person per month.
    • Quasi-mandate contract (jun-inin) — A contract to perform work diligently, without guaranteeing a finished deliverable; the standard form behind SES and much freelance project work.
    • Dispatch (haken) — A separate legal arrangement in which the client company directs the worker directly; different rules from SES.
    • Return rate (kangen-ritsu) — The share of an engineer’s client billing rate that reaches the engineer as salary or payment.
    • Sole proprietor (kojin jigyonushi) — The standard legal form for an independent freelance engineer in Japan.
    • Person-month billing — The monthly rate for one engineer, the standard unit of freelance and SES pricing in Japan.

    Summary

    Illustration of a layered landscape with mountains and clouds summarising Japan's IT industry

    Japan’s IT industry is a layered structure: end clients buy systems from SIers, SIers and their partners staff projects through subcontracting layers and SES arrangements, and independent engineers reach those projects mainly through freelance agents. Your experience of working in Japan — your rate, your support, your choices — depends less on the famous name attached to a project than on the layer you sit in and how the money flows past you. Learn the map first, and the rest of the decisions in this series — rates, margins, agents, taxes — become much easier to make.

    Next in this series: Freelance Engineer Rates in Japan (2026). Coming after that (in preparation): SES Margins and Return Rates — how much of your billing rate you actually keep.