Metabase row and column security

Metabase row and column security limits what each group can view and query, using user attributes and saved SQL policies. This page explains the options, the plan requirement and how to set it up without exposing other customers' data.

On this page

Metabase row and column security for governed group access

Several teams or customers often share one database, and each must see only its own rows and columns. Metabase row and column security, formerly called data sandboxing, solves this by filtering what a group can view and query, with one policy per table and group combination. It is available only on Pro and Enterprise plans, whether you self-host or use Metabase Cloud. Open source and Starter do not include it, so a team that needs group-level data restrictions must budget for a paid plan before it designs the access model.

The pricing page lists Open Source as free, Starter at $100 per month or $90 per month billed yearly with the first 5 users included, Pro at $575 per month or $517.50 per month billed yearly with the first 10 users included, and Enterprise priced by quote starting at $20,000 per year. Row and column permissions sit alongside SSO, multi-tenant data segregation and usage analytics and auditing, all of which are limited to Pro and Enterprise. Open source access controls, such as groups and collection permissions, may be enough when everyone in an organization can see the same data. Confirm with Metabase which features your intended plan includes before you commit, because pricing and inclusions change over time.

Before you choose this path, list every table that holds restricted data, the groups that need different views, and whether the restriction is by a single attribute such as region or by a more complex rule. Ask Metabase to confirm the current plan terms in writing, and plan the paid seat count against the number of people who will query restricted data. The Metabase row and column security documentation describes the policy types, and reading it early will show whether your rules fit a simple attribute filter or need a custom saved SQL question.

Attribute row filters versus custom SQL policies

This table compares the two ways to restrict rows in Metabase row and column security: a basic attribute filter on one column and a custom policy built from a saved SQL question. Read each row against your own access rules to see which policy type fits a given group and table, and what each one asks your team to maintain.

FactorBasic row policyCustom SQL policy
How it filtersMatches one column to a user attribute, such as a region or tenant IDRuns a saved SQL question that can filter on several columns
Columns handledFilters rows only, with no column changesCan restrict or edit which columns the group sees
Typical fitOne clear ownership key per table, such as tenant_id or sales_regionRules that combine conditions, derive values or hide sensitive fields
Maintenance effortLow: adjust the attribute mapping when groups or user attributes changeHigher: the SQL question must follow schema changes and be reviewed like code
Who can change itAdmins in the Metabase permissions settingsWhoever owns the saved question, so confirm ownership and review steps
Testing approachLog in as a test user in each group and confirm row countsCompare results against the source table for each attribute value and column set
Policy limitOne policy per table and group combinationAlso one policy per table and group combination, so combine conditions inside the SQL
Confirm before you buildWhether your database and plan support the filter you needWhether your plan includes the custom policy type and who will own the query

How to set up row and column security in Metabase

This sequence takes a self-hosted Metabase from a plan check to verified, per-group row and column restrictions, with each step closed by a test that shows the restriction works. Follow it in order, because each step depends on the groups, attributes and data permissions created before it.

  1. Confirm the plan supports row and column security

    Before any configuration, confirm that your Metabase edition is Pro or Enterprise, because row and column security is not included in the Open Source or Starter plans. This is done by the Metabase administrator with the licensing owner, using the current pricing and plan details on the Metabase pricing page. You know this step is complete when the admin settings show a paid plan that includes row and column permissions, and the license owner has confirmed the plan covers your self-hosted instance. If you are on the free edition, stop here, because the remaining steps will not be available.

  2. Map user attributes from your identity source

    Decide which attributes will drive each filter, such as a region, business unit, or customer ID, and confirm where each value lives in your identity provider or directory. The identity team and the Metabase administrator should do this together, and the output is a short written list of attribute names, their allowed values, and which users hold each one. Confirm that Metabase receives those attributes at login, either through the single sign-on setup or your directory sync, and test with one account that the values arrive as expected. Skipping this step is the most common cause of filters that return no rows for everyone.

  3. Create groups that match your access model

    Create one Metabase group for each set of users who should see the same data, and keep the groups aligned with the attribute values from the previous step. The Metabase administrator makes the groups in the admin settings and assigns users to them, either manually or through group sync if you use it. Review each group against your written access model so that no user lands in two groups with conflicting scopes. You know this step is done when every in-scope user appears in exactly one intended group and a test user from each group can sign in.

  4. Connect the database with restricted data permissions

    Add the target database to Metabase and set its data permissions so that each group has only the access it needs at the table level, with the broadest data access reserved for groups that should see everything. The administrator sets these in the Permissions section, and a database owner should confirm the connection uses an account whose privileges match the intended scope. Row and column policies sit on top of these table permissions, so a table the group cannot reach will not be restored by a filter. Confirm the result by signing in as a user from a restricted group and checking that only the allowed tables appear in the data browser.

  5. Define one row policy per table and group

    For each table that needs row filtering, create a basic policy that filters on a single column, and map that column to the user attribute from step two. Metabase allows one policy per table and group combination, so write the list of policies before building them to avoid duplicates. The administrator completes this in the permissions editor for each table. You know the policy works when a test user with a given attribute sees only the matching rows, and when the row count in a simple question matches the count you expect from the source table filtered by that value.

  6. Build custom SQL policies where basic filters fall short

    Where a restriction needs several columns or must hide or edit specific columns, write a saved SQL question that returns the permitted rows and columns, then base a custom policy on that question for the relevant group. The data owner writes the query and the Metabase administrator attaches it, and both should review the SQL for unintended joins or filters. Keep these queries short and documented, because each one becomes a control that must be maintained when the schema changes. The check is to sign in as a user in the affected group and confirm that hidden columns are absent from the results and that the row set matches the reference query run directly against the database.

  7. Test every group before users rely on it

    Run a full test pass across all groups using test accounts, and compare what each one sees in dashboards, saved questions, and the query builder with the expected results from the source system. Include the SQL editor, because a restricted user should not be able to bypass a policy by writing their own query, and check that exports and embedded content follow the same rules. Record the test results and the account used for each group, and have a second person repeat a sample of them. The step is complete when the test log shows no unexpected rows or columns and the sign-off names who approved the access model.

How a sandboxed query is filtered

The request starts when a user signs in to Metabase and Metabase resolves the user's groups and attributes. For each table, Metabase looks up the row and column policy that matches the group, then rewrites the query so it only reads permitted rows and columns. The trust boundary sits between Metabase and the database: confirm that the filtered query, not the original, is what reaches the database, and test each group with a sample account before release.

A user's query is narrowed by policy before it reaches the database.

Using row and column security for multi-tenant data

Multi-tenant data segregation in Metabase is a separate feature from row and column security, and it is licensed separately. Both sit on the Pro and Enterprise plans according to the pricing page, but they solve different problems. Row and column security limits what a group can see inside a table, based on user attributes and one policy per table and group combination. Multi-tenant data segregation is the control you use when many customers or business units share one Metabase instance and each must see only their own data. Before you design anything, confirm with Metabase that your plan includes multi-tenant segregation, because the pricing page lists it only for Pro and Enterprise and the exact configuration steps depend on your edition and version.

The core design decision is where tenant data lives. In a shared table with tenant filters, every customer's rows sit in the same table, and a tenant identifier column, carried in each user's attribute, drives the filter that Metabase applies to queries. This is the simplest model to operate, but a missing or wrong attribute value can expose rows, so the identifier must be populated from a trusted source such as your identity provider or a directory, not typed by hand. In a separate schema per tenant model, each customer has its own tables, and access is controlled at the database level through connection and permission design. This adds operational weight, since every new tenant means new objects and sync work, but a mistake in one filter cannot expose another schema. Choose based on tenant count, your database's own row-level security options, and how often tenants are onboarded.

Whichever model you choose, test cross-tenant leakage before any customer sees the instance. Create at least two test users in different tenant groups, then check every saved question, dashboard, model and embedded view that touches shared tables, including the query builder and any custom SQL questions, and confirm that each user sees only their own rows and columns. Include users with missing or blank attribute values, because those cases often fail open. Repeat the tests after every upgrade, after changes to group or attribute mappings, and after any new table joins. Record the results as evidence, and ask Metabase to confirm how multi-tenant segregation interacts with your chosen identity method. Metabase's row and column security documentation is the starting point for the policy details you will verify.

Security risks that row policies do not remove

A row and column policy limits what a group sees through the query builder and saved questions, but it does not cover every path to the data. The cards below cover the paths that remain open, the admin and identity settings that can widen access without anyone noticing, and the logging you need to prove what was seen.

Raw SQL bypasses intent

Row and column policies on Pro and Enterprise apply to what a group can view and query, but users with native query access can write their own SQL against the underlying tables. Check which groups hold native query permission on each database, and whether those groups need the sandboxed tables at all. Where native access is needed, test whether the policy still applies to the questions those users write, and confirm that behavior in your own environment before you rely on it.

Row and column security docs

Exports leave the policy scope

A filtered table can still leave Metabase as a CSV, XLSX or PDF if the group can download results. Review download permissions per group and decide which sandboxed groups may export at all. Treat each exported file as a copy of the data the policy was meant to restrict, and plan where those files are stored and who can open them.

Public links and embeds

Public links and embedded dashboards show content to people who may not hold a Metabase account, so a policy tied to a user attribute does not describe what those viewers see. Confirm which dashboards and questions are shared publicly, and which embed authentication method is in use. Guest embeds and SSO-based embeds have different access paths, so review each one against the tables it exposes.

Admins see all data

Administrators and members of the admin group are not limited by row and column policies in the same way as other groups. Keep the admin group small, document who holds it, and avoid using admin accounts for day-to-day analysis. Ask your vendor or test team to confirm how admin access interacts with each sandboxed table before sign-off.

Identity attribute mapping errors

Row filters depend on user attributes that usually come from the identity provider through JWT, SAML, OIDC or LDAP sync. A missing, renamed or mis-mapped attribute can give a user an empty result or, worse, another tenant's rows. Test each identity provider mapping with accounts from every sandboxed group, and review the attribute sync after every change on the identity side.

Audit logging of who saw what

A policy controls access but does not, by itself, give you a record of who viewed which rows. Confirm which activity and audit records your plan retains, how long they are kept in your environment, and whether they can be forwarded to your log platform. Define the questions you need to answer during an access review before you rely on the logs to answer them.

Questions buyers ask before setting up row and column security

Which Metabase plan do I need for row and column security?

Row and column security requires a Pro or Enterprise plan, whether you self-host or use Metabase Cloud. It is not included in Open Source or Starter. According to the Metabase pricing page, Pro is $575 per month or $517.50 per month billed yearly, with the first 10 users included and additional users at $12 per month. Enterprise is priced by quote starting at $20,000 per year. Confirm current figures on the Metabase pricing page before you budget, since the page is the source of truth for list prices.

Can I approximate row and column security on the open source edition?

Only partly. Open Source has no row and column permissions, so you cannot restrict what a group sees inside Metabase itself. Common workarounds include separate Metabase instances per customer or group, or separate database connections with credentials limited at the database level. Each workaround adds servers, databases and patching to run, and none gives you the per-group policies that the paid plans provide. Weigh the license cost against the operating cost of those workarounds before you decide.

How long does row and column security setup take, and what drives the effort?

The effort depends mainly on how many tables, groups and tenants need policies, and how many of those policies are custom SQL. Basic row policies on a single column for a few groups are a small task. Custom policies based on saved SQL questions, column restrictions and multi-tenant isolation take longer because each one needs a query, testing and review. Ask any partner for a written scope that lists tables, groups, policy types and test cases, since that list drives both timeline and quote.

What does my team need to provide before setup starts?

Plan to provide four things before work begins:

  • Read access to the source databases, with a clear list of which schemas and tables are in scope
  • The attribute source that defines each user's tenant, region or group, such as user attributes set in your identity provider or in Metabase
  • Test accounts in each group, so every policy can be checked from the user's point of view
  • Named owners who can approve the policy rules and sign off on the test results

Missing any of these typically adds rounds of back and forth.

Can my internal team set up row and column security alone?

Often yes, if the team already runs Metabase and understands the database schema and the access model. Basic row policies are configured in the admin interface. Custom SQL policies need SQL skill and a clear test plan. The harder part is testing that no user can reach rows or columns outside their scope, including through the query builder and saved questions. If your team cannot dedicate time to that testing and review, a fixed-scope engagement with written deliverables can cover it.

How are custom SQL policies maintained over time?

Custom policies are saved SQL questions, so they change when the underlying schema changes. A renamed column or a new table can silently break a filter or expose data, so treat each policy as code. Keep a list of every policy with its owner and purpose, re-test after schema changes and after Metabase upgrades, and review access when people change groups. Ongoing retainers can cover this review and retesting if your team does not want to own it internally.

Does row and column security work for multi-tenant deployments?

It can, and it is one of the reasons teams buy the paid plans. Multi-tenant data segregation is included in Pro and Enterprise, and row policies can filter each tenant's rows by a user attribute. Confirm in your own environment that tenant attributes are set reliably at sign-in, because a missing or wrong attribute is a common source of data exposure. Test with accounts from at least two tenants before you go live.

How DeployOpen scopes row and column security work

Row and column security is scoped in writing before any policy is built. DeployOpen agrees with your team which tables, groups and user attributes are in play, which rows and columns each group may see, and which permission model fits each case: an attribute-based row filter, a custom policy built on a saved SQL question, or a mix of both. The agreed list of policies and table and group combinations becomes the baseline for the work, along with the test cases that will prove each policy holds. Most engagements are fixed-scope, so the deliverables and timeline are fixed in the same document. Ask for that document to name each table and group pair, the attribute source for each filter, and who approves changes to it.

The build is followed by a verification run, not just a configuration handover. Each group is tested from its own account, checking what it can view in the interface and what it can query, including questions built in the query builder and SQL. Cross-group tests confirm that one group cannot see another group's rows or hidden columns, and that a change to a user attribute changes results as expected. Because a custom SQL policy can restrict or edit columns, the tests also cover the columns a group should never see. Your team should confirm that the test accounts reflect real membership in your identity provider, and that the Pro or Enterprise plan that enables this feature is in place before the build starts.

Handover includes configuration records, the test results and notes on how to add a table, group or policy without breaking existing rules. DeployOpen can also support the instance on an ongoing basis under a retainer, covering policy changes, upgrades and repeat testing after new tables or groups are added. Ask any provider to state in writing what the retainer covers and how changes to the agreed scope are priced and approved.

How DeployOpen works on this

DeployOpen plans and builds Metabase row and column security as a fixed-scope engagement inside your own infrastructure. We start from the access model your data owners already use, then test that each group sees only the rows and columns it should, and hand over the policies with documentation your team can maintain.

How we scope

  • Inventory which tables, groups and user attributes need row filters, column restrictions or both before any policy is written.
  • Confirm the Metabase plan that carries row and column security, since it requires Pro or Enterprise, self-hosted or on Metabase Cloud.
  • Agree in writing which policies use attribute-based filters and which need custom SQL views, with deliverables and timelines fixed before work starts.

How we build

  • Configure one policy per table and group combination, keeping each filter tied to a single documented user attribute where possible.
  • Build custom policies from saved SQL questions only where multi-column filtering or column editing is required, and review each query.
  • Test every group against sample accounts, checking that filtered rows and hidden columns match the written access matrix.

How we hand over

  • Deliver a policy register listing each table, group, attribute and filter, so reviewers can trace who sees what.
  • Document the test cases and results so your security or compliance team can repeat them after changes.
  • Walk your administrators through adding groups, attributes and policies, and the checks to run before each change reaches production.

How we support

  • Offer ongoing support, upgrades and continuous testing as a retainer, covering row and column policies after each Metabase upgrade.
  • Retest policies after schema changes, new data sources or new groups, and report any gaps against the agreed scope.
  • Confirm with your team how multi-tenant segregation and the upgrade schedule for your Metabase version will be handled before go-live.

Sources and further reading

Talk to our team.

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

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