Django media isn't loading

I am trying to dynamically show media files which are uploaded with admin page. I am able to save the files and view it on the directory and database, however its not showing on the webpage.

My settings.py

MEDIA_ROOT = os.path.join(BASE_DIR, '')
MEDIA_URL = '/uploads/'

Urls.py

path('xxxxx/', include('xxxxx.urls')),
]+  static(settings.MEDIA_URL, document_root=settings.MEDIA_ROOT)

Filepath on database

media/2023/01/17/3.png

Filepath in directory

/project/media/2023/01/17
Back to Top