Bolt storage

Cloud Storage Permissions Misconfigured in Bolt App

Your Bolt.new application fails to upload, read, or delete files from cloud storage. Users get permission denied errors when trying to upload profile pictures, access shared documents, or view images that should be publicly visible.

Cloud storage services like Supabase Storage and AWS S3 use policy-based access control. If these policies are too restrictive, legitimate operations fail. If they're too permissive, anyone on the internet can read or modify your files. Bolt's AI often generates storage code without configuring the bucket policies correctly.

This typically surfaces right after connecting cloud storage: uploads fail with RLS policy violations, images return 403 errors, or users can see other users' private files because the policies are set to public.

Error Messages You Might See

StorageApiError: new row violates row-level security policy 403 Forbidden: Access denied to storage object Error: Bucket not found StorageApiError: The resource already exists Policy check failed for storage.objects
StorageApiError: new row violates row-level security policy403 Forbidden: Access denied to storage objectError: Bucket not foundStorageApiError: The resource already existsPolicy check failed for storage.objects

Common Causes

  • Supabase RLS not configured — Storage bucket has Row Level Security enabled but no policies defined, blocking all operations
  • Bucket set to private without access policies — The bucket is private (correct) but no policies allow authenticated users to upload or read their files
  • Public bucket exposing all files — The bucket is set to public, letting anyone access any uploaded file including private user documents
  • Wrong storage bucket name — Code references a bucket name that doesn't exist or is misspelled in the Supabase dashboard
  • Service role key used on client — The Supabase service_role key bypasses RLS in development but the anon key used in production respects RLS policies

How to Fix It

  1. Create proper RLS policies — In Supabase dashboard, add storage policies: allow authenticated users to upload to their own folder (auth.uid()::text = (storage.foldername(name))[1])
  2. Set bucket visibility correctly — Use private buckets for user files and create signed URLs for access: const { data } = await supabase.storage.from('private').createSignedUrl(path, 3600)
  3. Use folder-based isolation — Store files in user-specific folders: uploads/{userId}/filename.jpg and restrict access by folder ownership
  4. Test with anon key — Always test storage operations with the anon key, not service_role, to catch RLS issues before production
  5. Add public bucket for assets — Create a separate public bucket for truly public assets like product images, and keep user uploads in private buckets

Real developers can help you.

Omar Faruk Omar Faruk As a Product Engineer at Klasio, I contributed to end-to-end product development, focusing on scalability, performance, and user experience. My work spanned building and refining core features, developing dynamic website templates, integrating secure and reliable payment gateways, and optimizing the overall system architecture. I played a key role in creating a scalable and maintainable platform to support educators and learners globally. I'm enthusiastic about embracing new challenges and making meaningful contributions. PawelPloszaj PawelPloszaj I'm fronted developer with 10+ years of experience with big projects. I have small backend background too Caio Rodrigues Caio Rodrigues I'm a full-stack developer focused on building practical and scalable web applications. My main experience is with **React, TypeScript, and modern frontend architectures**, where I prioritize clean code, component reusability, and maintainable project structures. I have strong experience working with **dynamic forms, state management (Redux / React Hook Form), and complex data-driven interfaces**. I enjoy solving real-world problems by turning ideas into reliable software that companies can actually use in their daily operations. Beyond coding, I care about **software quality and architecture**, following best practices for componentization, code organization, and performance optimization. I'm also comfortable working across the stack when needed, integrating APIs, handling business logic, and helping transform prototypes into production-ready systems. My goal is always to deliver solutions that are **simple, efficient, and genuinely useful for the people using them.** Simon A. Simon A. I'm a backend developer building APIs, emulators, and interactive game systems. Professionally, I've developed Java/Spring reporting solutions, managed relational and NoSQL databases, and implemented CI/CD workflows. Sage Fulcher Sage Fulcher Hey I'm Sage! Im a Boston area software engineer who grew up in South Florida. Ive worked at a ton of cool places like a telehealth kidney care startup that took part in a billion dollar merger (Cricket health/Interwell health), a boutique design agency where I got to work on a ton of exciting startups including a photography education app, a collegiate Esports league and more (Philosophie), a data analytics as a service startup in Cambridge (MA) as well as at Phillips and MIT Lincoln Lab where I designed and developed novel network security visualizations and analytics. I've been writing code and furiously devoted to using computers to make people’s lives easier for about 17 years. My degree is in making computers make pretty lights and sounds. Outside of work I love hip hop, the Celtics, professional wrestling, magic the gathering, photography, drumming, and guitars (both making and playing them) David Olverson David Olverson Solo dev shipping production apps with AI-assisted development. I specialize in rescuing broken Lovable/Bolt/Cursor builds and taking them to production. 10+ apps shipped including SaaS CRMs, gaming platforms, real estate tools, and Discord bots. Stack: Next.js 16, TypeScript, Tailwind CSS, FastAPI, PostgreSQL, Prisma. I use Claude Code with 50+ custom skills for rapid delivery. Average turnaround: 2-4 weeks from broken prototype to production. ISHANTDEEP SINGH ISHANTDEEP SINGH Senior Software Engineer with 7+ years of experience in React, JavaScript, TypeScript, Next.js, and Node.js. I’ve also worked as a tech lead for startups, owning end-to-end technical execution including architecture, development, scaling, and delivery. I bring a strong mix of hands-on coding, product thinking, and technical leadership, and I’m comfortable building products from scratch as well as improving and scaling existing systems. Anthony Akpan Anthony Akpan Developer with 8 years of experience building softwares fro startups Matthew Jordan Matthew Jordan I've been working at a large software company named Kainos for 2 years, and mainly specialise in Platform Engineering. I regularly enjoy working on software products outside of work, and I'm a huge fan of game development using Unity. I personally enjoy Python & C# in my spare time, but I also specialise in multiple different platform-related technologies from my day job. Basel Issmail Basel Issmail ’m a Senior Full-Stack Developer and Tech Lead with experience designing and building scalable web platforms. I work across the full development lifecycle, from translating business requirements into technical architecture to delivering reliable production systems. My work focuses on modern web technologies, including TypeScript, Angular, Node.js, and cloud-based architectures. I enjoy solving complex technical problems and helping teams turn product ideas and prototypes into working platforms that can grow and scale. In addition to development, I often collaborate closely with product managers, business analysts, designers, and QA teams to ensure that solutions align with both technical and business goals. I enjoy working with startups and product teams where I can contribute both as a hands-on engineer and as a technical partner in designing and delivering impactful software.

You don't need to be technical. Just describe what's wrong and a verified developer will handle the rest.

Get Help

Frequently Asked Questions

Should my Supabase Storage bucket be public or private?

Use private buckets for user-uploaded content (profile photos, documents). Use public buckets only for assets that genuinely need to be accessible to anyone (product images, marketing assets). Always configure RLS policies regardless of visibility.

Why does storage work in development but not production?

In development, you might be using the service_role key which bypasses all RLS policies. In production, the anon key is used and respects RLS. Create proper storage policies that allow authenticated users to manage their own files.

Related Bolt Issues

Can't fix it yourself?
Real developers can help.

You don't need to be technical. Just describe what's wrong and a verified developer will handle the rest.

Get Help