Security in m51.ai: How we protect your customer data
Where the data lives, how customers are kept apart, what we encrypt and how changes to ad accounts are approved. Reviewed and updated November 2026.
Last updated 1 November 2026. The article was first published in April 2026. Since then we have moved our hosting to Google Cloud in the EU and tightened sign-in, so we have checked every claim again.
Marketing data is sensitive. Campaign budgets, customer lists, ad results and access to your ad accounts at Google, Meta and LinkedIn all end up in one place. That is why security is part of the architecture, not something added at the end.
This article describes the measures that are in place today. What we do not have yet is listed in its own section at the end.
In short
- The database and files are stored with Supabase in the EU (Ireland). The application runs on Google Cloud in the EU (Belgium).
- Each customer's data is kept apart from everyone else's. API requests that concern a customer check that the user has access to that exact customer.
- Access to ad accounts and CMSs is encrypted when it is saved, with a key that is not kept in the database.
- Sign-in with password and MFA through an authenticator app, with limits on the number of attempts.
- Changes the agents make to ad accounts and published content arrive as proposals that must be approved before they are carried out. The exceptions are listed in the section on approval.
- We regularly review the entire codebase for vulnerabilities and fix findings by severity.
Where the data lives
Customer data is stored in the EU. The database and files are hosted by Supabase in Ireland. The application runs on Google Cloud Run in Belgium (europe-west1). The backup of files is stored with Cloudflare R2, restricted to EU storage.
Some subprocessors process data outside the EU/EEA. These include the language models from Anthropic and OpenAI, email delivery and the ad platforms themselves. Transfers rely on the EU-US Data Privacy Framework (DPF) or the EU Standard Contractual Clauses (SCC). Operational logs in Google Cloud Logging may also be processed outside the EU/EEA. The full list, with purpose and country, is in our privacy policy.
As a pilot, the AI assistant in Chat can run on Mistral, a European provider. It is enabled for individual customers.
Data isolation between customers
Customer data is tied to a customer ID. API requests that concern a customer check that the signed-in user has access to that exact customer. If not, the request is rejected.
Row-Level Security (RLS) is enabled on every table in the application's database schema, 435 as of 1 November 2026. The public client key gives no access to the tables with customer data. A few tables also have policies for other roles, for example for signed-in users' own rows or own company and for public price lists.
The backend uses a privileged database role that bypasses RLS. Isolation between customers is therefore enforced in the application, and it is tested automatically:
- A guard test walks through every API route, more than 1,000 of them, and fails the build if a route lacks authentication. Public API routes must be on a separate list with a stated reason.
- Dedicated tests try to read and change other customers' data and require a rejection (403 or 404).
- New database tables are checked automatically for RLS before the change can be merged.
Encryption
In transit and at rest
The website and the app use HTTPS with HSTS. Between Cloudflare and the application, traffic goes through an encrypted tunnel, and the application on Google Cloud only accepts requests that carry a valid Google identity.
Data at rest is encrypted with AES-256 at Supabase, Google Cloud and Cloudflare.
Access to ad accounts and tools
When you connect Google, Meta, LinkedIn, Microsoft Advertising or Snapchat, we store the access tokens (OAuth tokens) encrypted at field level. This covers the access token, the refresh token and the email address of the connected account. API keys for HubSpot, Shopify, WordPress, Sanity and Webflow are encrypted the same way when they are saved.
We use Fernet (AES-128-CBC with HMAC-SHA256), which both prevents reading and detects tampering. Each value is bound to the customer and the platform, and OAuth tokens also to the field. If a value is moved to another customer's row, it cannot be decrypted and is treated as invalid. The application encrypts the values before they are written to the database.
The encryption key is not stored in the database, so the encrypted values cannot be read from a copy of the database alone. Keys can be rotated without downtime and without anyone having to sign in again. New keys encrypt, and old keys are kept only for reading.
Passwords and sign-in secrets
Passwords are stored as bcrypt hashes, and so are the MFA recovery codes. Sign-in sessions and password reset links are stored only as SHA-256 hashes, and a password reset link works once. MFA secrets are encrypted with a separate key.
Sign-in and access control
Sign-in is our own. The access token lasts 60 minutes, and the session is replaced every time it is renewed. If an old session key is reused, every session in that chain is revoked.
After five wrong passwords on the sign-in page, the user has to wait 15 minutes before trying again. Sign-in, registration, password changes and MFA have their own limits on attempts per minute. When you change your password, all other sessions are signed out. When a user is deactivated, that user loses access.
Two-factor authentication (MFA)
MFA is built in. You use a standard authenticator app (TOTP), such as Google Authenticator, 1Password or Authy. During setup you receive ten recovery codes in case you lose your phone. Failed sign-in attempts are counted per user in the database, not only per IP address. Each user turns on MFA themselves, and we recommend that everyone does.
Roles
A user can have access to one or more companies. The owner of a company manages billing and invites colleagues. What a user can do also depends on the subscription. Access is checked on the server, not only in the interface.
Approval before changes to ad accounts and CMSs
The AI assistant and the other agents can propose changes to ad accounts, websites and online stores. A proposal becomes an approval card, and nothing is carried out until the card has been approved. Who approved it is logged.
- Writing is off by default. Both the company and the individual user must turn it on for each platform.
- Access is checked again when the proposal is carried out. If a switch has been turned off in the meantime, the action stops.
- Changes to budgets require the amount to be typed in again on the card.
- We have an emergency brake per ad platform that stops new changes from the agents.
- Changes carried out in ad accounts are recorded in a separate audit log per platform. A rollback is a new proposal that goes through the same approval.
There are a few exceptions. Rule-based pausing of Google Ads campaigns is off by default. Only M51 can turn it on for an account, and it never applies to budgets or bidding. When writing is turned on, M51 can also do the following without an approval card: write unpublished drafts, add images and video to the ad account's media library and publish replies to comments. Replies to comments require the feature to be turned on for the company.
Protecting the AI layer
An AI platform has attack surfaces that a regular web app does not. The main ones are hidden instructions that try to steer the model (prompt injection) and attempts to make the server fetch internal addresses (SSRF).
- The user's message is checked against more than 30 known injection patterns in several languages and given a risk score before it is sent to the model. The text is normalised first, so more variants that use special characters are caught.
- Content from your documents is marked as data, not instructions, before it is sent to the model.
- The agents' tools for fetching web pages check the address and reject internal and private addresses, including cloud metadata.
The filters reduce the risk, but no filter catches everything. That is why changes to ad accounts and published content are governed by approvals and switches, not by the filters alone.
Secrets and operations
The application's production secrets are kept in Google Secret Manager, pinned to a specific version, and loaded when the service starts. The application refuses to start if a critical key is missing or too short. GitHub scans the code for keys committed by mistake and blocks known key formats on push.
The application runs without root privileges, and containers are built from base images pinned to a specific version. New application code is only deployed from the main branch after all automated checks have passed, and deployments use no stored cloud keys.
Server responses carry security headers: HSTS, Content-Security-Policy, X-Content-Type-Options: nosniff, Referrer-Policy and Permissions-Policy. The app cannot be embedded on other websites.
Logging and monitoring
- Changes to access are logged: invitations, memberships with role and subscriptions.
- Selected administrative actions by M51 are logged with the state before and after.
- Changes carried out in ad accounts have their own audit log, as described above.
- Availability is checked every minute from six regions, and we are alerted automatically when the service does not respond.
Backups
The database is backed up daily at Supabase in the EU. Files are copied every night to a different provider, Cloudflare R2, with storage in the EU. Earlier versions of files are kept for 30 days and are protected against deletion. Restoring from the backup has been tested, including recovering a file.
Incidents and notification
If there is a personal data breach, we notify you without undue delay and no later than 72 hours. The notice describes the scope and what we are doing. This is set out in the data processing agreement. Where we are the controller, we notify the Norwegian Data Protection Authority within 72 hours.
When we add or replace a subprocessor that processes personal data, we notify you, and you can object within a reasonable deadline. This is also set out in the data processing agreement.
Subprocessors and agreements
The main subprocessors for hosting and storage:
| Provider | What they do | Where |
|---|---|---|
| Supabase | Database and files | EU (Ireland) |
| Google Cloud | Application hosting | EU (Belgium) |
| Cloudflare | DNS, TLS and attack protection | USA (global network) |
| Sentry | Error monitoring | EU (Frankfurt) |
| Anthropic and OpenAI | Language models | USA |
The full list is in our privacy policy (version 1.16, 29 October 2026). The data processing agreement is part of our terms (version 2026-10-29-v8).
Privacy policy with all subprocessors
Terms and data processing agreement
Regular security reviews
We review the entire codebase for vulnerabilities on a regular basis. The review covers access control, isolation between customers, encryption, dependencies, the AI layer and the build pipeline. Findings are given a severity, the most serious are verified one by one, and fixes are prioritised by severity. The most recent full review was completed in November 2026.
As a rule, code changes also get an independent AI code review, documented per change, before they are merged. The test suite, more than 90,000 automated tests, runs in the merge queue on exactly the code that is about to be merged. New tables are checked for RLS, new API routes for authentication and new dependencies for known vulnerabilities.
What we do not have yet
- Formal certifications such as SOC 2 or ISO 27001. We do not have these as of November 2026, and we are happy to discuss specific requirements.
- MFA cannot be made mandatory for every user in a company. Each user turns it on themselves.
Reporting a vulnerability
If you have found a vulnerability in m51.ai, we want to hear about it. Email [email protected] with a description and the steps to reproduce it. We reply within two business days. We will not take legal action against anyone who reports in good faith.
Do not test against data that belongs to others. If you need a test environment, contact us first and we will set up a separate account.
About m51.ai
m51.ai gives in-house marketing teams specialised AI agents for content, SEO, advertising and campaign optimisation. These measures are in place because our customers give us access to the core of their business.
Want to see the platform in use? Book a demo.
Book demoFrequently asked questions
Where is our data stored?
Customer data is stored in the EU. The database and files are hosted by Supabase in Ireland, and the application runs on Google Cloud in Belgium. Some subprocessors, including the language models from Anthropic and OpenAI, process data in the USA under the DPF or the EU Standard Contractual Clauses. The full list is in our privacy policy.
How is data isolated between customers?
Customer data is tied to a customer ID, and API requests that concern a customer check that the signed-in user has access to that customer. A guard test fails the build if an API route lacks authentication, and dedicated tests try to read other customers' data and require a rejection. Row-Level Security is enabled on every table in the application's database schema, and the public client key gives no access to customer data.
Where are our Meta, LinkedIn and Google Ads credentials stored?
OAuth tokens are stored encrypted at field level with Fernet (AES-128-CBC and HMAC-SHA256). Each value is bound to the customer, the platform and the field. The encryption key is not stored in the database, so the encrypted values cannot be read from a copy of the database alone. API keys for HubSpot, Shopify, WordPress, Sanity and Webflow are encrypted the same way.
Does m51.ai support two-factor authentication?
Yes. You use an authenticator app (TOTP), such as Google Authenticator, 1Password or Authy, and receive ten recovery codes during setup. Each user turns on MFA themselves, and we recommend that everyone does.
Can the AI assistant change our ad accounts without our approval?
Changes arrive as proposals on an approval card, and writing stays off until both the company and the user turn it on. The exceptions are rule-based pausing of Google Ads campaigns, which only M51 can turn on and which never applies to budgets or bidding, and that M51 can, without a card, write unpublished drafts, add images and video to the media library and reply to comments when writing is turned on.
Do you have SOC 2 or ISO 27001 certification?
No, not as of November 2026. This article describes the technical measures that are in place. If your organisation requires certification, get in touch. We will tell you honestly where we stand and share documentation of the controls.
How do I report a vulnerability?
Email [email protected] with a description and the steps to reproduce it. We reply within two business days and will not take legal action against anyone who reports in good faith.