Django admin template css is not loaded when deployed on Vercel?

On deploying my project to vercel hosting platform everything works successfully but when i try to access my admin panel it shows only the content with no styles.

message profile
Admin
2022-04-09

This is occuring becuase your static files are not being served in production on vercel. check our How to deploy a django project with staticfiles on vercel and ensure to pay attention to the part about running collectstatic using the builds_sh file and also ensure that this code is present in your settings.py file.

STATICFILES_DIRS = os.path.join(BASE_DIR, 'static'),
STATIC_ROOT = os.path.join(BASE_DIR, 'staticfiles_build', 'static')

 

Add Message

Click on the button below to add a new message to this thread

Tags

Thread detail

Satus: Open
Messages: 1Started: 2022-04-09
loading..

DEVMAESTERS

Newsletter

Services

Frontend Development |Backend Development |Full Website Development |Bootstrap Website upgrades | Website Debbugging | Website Hosting & deployment

Contact

Interested in hiring me or collaborating with me on a project, click on any of the links below to get my social media handle

Or contact me via Tel: (+234)-806-225-7480 | Email: abubakarzakari1703@gmail.com

Copywright@devmaesters.com
Privacy Policy

By using our website,
you agree that devmaesters can store cookies on your device and disclose information in accordance with our privacy policy.