How to Configure BigQuery Read Only User
You set up a bigquery read only user by pairing data viewer and job roles. One role lets the user read tables, while the other lets them run query jobs. Many teams start by giving broad project roles to get analysts working fast. Broad roles often let users change tables, delete data, or view every dataset by mistake. Splitting read rights from job rights keeps your data safe from accidental changes. How a bigquery read only user role works Cloud data warehouses separate storage rights from c
Your coding agents run with your access.
Claude Code reaches prod with a developer's credentials, and approval prompts get clicked through. hoop.dev checks every query, masks sensitive data, and holds risky changes for a human.
You set up a bigquery read only user by pairing data viewer and job roles. One role lets the user read tables, while the other lets them run query jobs. Many teams start by giving broad project roles to get analysts working fast. Broad roles often let users change tables, delete data, or view every dataset by mistake. Splitting read rights from job rights keeps your data safe from accidental changes.
How a bigquery read only user role works
Cloud data warehouses separate storage rights from compute rights in their permission model. A user needs two distinct permissions to run a standard query against a table. First, the user needs permission to start a query job inside the cloud project. Without job rights, the user can browse table names but cannot run any queries. Second, the user needs viewer permission on the specific dataset or table they want. You can grant viewer rights at the project, dataset, or single table level. Granting viewer rights at the dataset level is the most common team choice. It stops the user from reading other datasets stored in the very same project. The user also cannot insert rows, drop tables, or change any table schemas. When the user sends a query, the cloud platform checks both roles before running it. If both checks pass, the engine reads the data and returns the query results.
Why you should scope viewer permissions to datasets
Project level viewer roles give a user read rights across every dataset in that project. New datasets added later also inherit those same broad project read permissions right away. A finance table or human resources table might land in that shared project later. Scoping viewer roles to individual datasets prevents that accidental exposure of sensitive team tables. You still grant the job runner role at the project level so queries work. Then you attach the data viewer role only to the datasets each group needs. You can also use authorized views when a user needs only a few columns. An authorized view lets a user query a filtered view without reading the base table. This setup takes a bit more planning when you add new analysts or apps. Still, it keeps each team inside its own data boundary as your warehouse grows.
What native read roles solve and what they leave open
Native cloud roles do a great job of blocking writes and table drops. They also record who logged in and which tables a query job scanned. Still, static read roles only check if a user can read a whole table. Once a user has table access, every query returns raw rows to their screen. Native roles do not inspect or rewrite individual results as queries run in flight. If a table holds emails, phone numbers, or card numbers, the viewer sees them. Building separate views or policy tags for every column and group takes steady upkeep. Service accounts for business apps also create a blind spot in native audit logs. Many people share one reporting app, so the log only shows the app key. Teams often need a way to mask sensitive fields like national IDs in results. They also want to tie every read query back to an individual person.
Read-Only Root Filesystem + User Provisioning (SCIM): architecture patterns and best practices
Continue reading? Get the full guide.
Free. No spam. Unsubscribe anytime.
Check database and API queries on the wire
Identity tools, roles, and network rules decide who opens a session. Setup alone cannot check what each query does or mask sensitive values in a response once a session starts. When workflows touch Postgres, MySQL, SQL Server, MongoDB, ClickHouse, Kubernetes APIs, SSH, or internal HTTP APIs, hoop.dev sits inline in the wire protocol beside those services as an open-source proxy, a sidecar for your Postgres or API. On every query an AI agent or engineer runs against production, hoop.dev decides to pass, mask, block, or hold it for human review.
Your login details and client tools stay as they are while hoop.dev guardrails refuse bad deletes or drops before they run, and hoop.dev data masking rewrites matched sensitive values in responses in memory. Furthermore, hoop.dev holds SOC 2 Type II, is MIT licensed, and writes every query and decision to an audit trail that generates evidence for HIPAA, GDPR, and PCI DSS. See the source on GitHub.
Frequently asked questions
Why can my read only user see tables but not run queries?
The user has data viewer rights on the dataset, which shows table metadata. You must also grant a job runner role at the project level to run queries.
Should I grant data viewer roles at the project or dataset level?
Grant data viewer roles at the dataset or table level whenever you can. Project level viewer roles grant read access to every current and future dataset there.
Can a read only user still read sensitive fields in a table?
Yes, standard table viewer roles return all columns and rows in that table by default. To hide emails or card numbers, you need column policies or result masking.
Related guides
In this post