# Having troubles with django project on deployment on vercel

**URL:** <https://forum.djangoproject.com/t/having-troubles-with-django-project-on-deployment-on-vercel/24269>\
**Category:** Deployment\
**Created:** [October 3, 2023, 4:16am UTC](https://forum.djangoproject.com/t/having-troubles-with-django-project-on-deployment-on-vercel/24269 "2023-10-03T04:16:45Z")\
**Posts on this page:** 20\
**Page:** 1

<div class="post-metadata">

**Author:** ![theprateekgoyal2](https://sea2.discourse-cdn.com/flex026/user_avatar/forum.djangoproject.com/theprateekgoyal2/32/16081_2.png) [@theprateekgoyal2](https://forum.djangoproject.com/u/theprateekgoyal2)\
**Post date:** [October 3, 2023, 4:16am UTC](https://forum.djangoproject.com/t/having-troubles-with-django-project-on-deployment-on-vercel/24269/1 "2023-10-03T04:16:45Z")

</div>

Hey folks, I am learner. Have build my django project using python 3.11 and when It cam to deploy. I tried many things but none worked in the end I tried vercel but I am getting errors here too

```auto
[09:34:21.181] Running build in Washington, D.C., USA (East) – iad1 (Hive)
[09:34:21.285] Cloning github.com/theprateekgoyal2/expenseswebsite (Branch: main, Commit: ecfdf0a)
[09:34:21.624] Previous build cache not available
[09:34:21.767] Cloning completed: 481.175ms
[09:34:22.107] Running "vercel build"
[09:34:22.554] Vercel CLI 32.3.1
[09:34:22.706] WARN! Due to `builds` existing in your configuration file, the Build and Development Settings defined in your Project Settings will not apply. Learn More: https://vercel.link/unused-build-settings
[09:34:24.436] Collecting asgiref==3.7.2 (from -r requirements.txt (line 1))
[09:34:24.436] Obtaining dependency information for asgiref==3.7.2 from https://files.pythonhosted.org/packages/9b/80/b9051a4a07ad231558fcd8ffc89232711b4e618c15cb7a392a17384bbeef/asgiref-3.7.2-py3-none-any.whl.metadata
[09:34:24.459] Downloading asgiref-3.7.2-py3-none-any.whl.metadata (9.2 kB)
[09:34:24.520] Collecting Brotli==1.1.0 (from -r requirements.txt (line 2))
[09:34:24.520] Obtaining dependency information for Brotli==1.1.0 from https://files.pythonhosted.org/packages/e2/e6/4a730f6e5b5d538e92d09bc51bf69119914f29a222f9e1d65ae4abb27a4e/Brotli-1.1.0-cp39-cp39-manylinux_2_5_x86_64.manylinux1_x86_64.whl.metadata
[09:34:24.525] Downloading Brotli-1.1.0-cp39-cp39-manylinux_2_5_x86_64.manylinux1_x86_64.whl.metadata (5.5 kB)
[09:34:24.556] Collecting certifi==2023.7.22 (from -r requirements.txt (line 3))
[09:34:24.557] Obtaining dependency information for certifi==2023.7.22 from https://files.pythonhosted.org/packages/4c/dd/2234eab22353ffc7d94e8d13177aaa050113286e93e7b40eae01fbf7c3d9/certifi-2023.7.22-py3-none-any.whl.metadata
[09:34:24.561] Downloading certifi-2023.7.22-py3-none-any.whl.metadata (2.2 kB)
[09:34:24.796] Collecting cffi==1.15.1 (from -r requirements.txt (line 4))
[09:34:24.800] Downloading cffi-1.15.1-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (441 kB)
[09:34:24.812] ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 441.2/441.2 kB 47.3 MB/s eta 0:00:00
[09:34:24.837] Collecting cssselect2==0.7.0 (from -r requirements.txt (line 5))
[09:34:24.841] Downloading cssselect2-0.7.0-py3-none-any.whl (15 kB)
[09:34:24.854] Collecting dirtree==0.3.0.dev0 (from -r requirements.txt (line 6))
[09:34:24.859] Downloading dirtree-0.3.0.dev0-py3-none-any.whl (3.7 kB)
[09:34:24.877] Collecting distlib==0.3.7 (from -r requirements.txt (line 7))
[09:34:24.877] Obtaining dependency information for distlib==0.3.7 from https://files.pythonhosted.org/packages/43/a0/9ba967fdbd55293bacfc1507f58e316f740a3b231fc00e3d86dc39bc185a/distlib-0.3.7-py2.py3-none-any.whl.metadata
[09:34:24.881] Downloading distlib-0.3.7-py2.py3-none-any.whl.metadata (5.1 kB)
[09:34:24.897] Collecting dj-database-url==2.1.0 (from -r requirements.txt (line 8))
[09:34:24.897] Obtaining dependency information for dj-database-url==2.1.0 from https://files.pythonhosted.org/packages/21/d2/b90366de4682c1472748b848292054e0960673f3c7d1a9d08fb227fad819/dj_database_url-2.1.0-py3-none-any.whl.metadata
[09:34:24.901] Downloading dj_database_url-2.1.0-py3-none-any.whl.metadata (11 kB)
[09:34:25.017] Collecting Django==4.2.5 (from -r requirements.txt (line 9))
[09:34:25.018] Obtaining dependency information for Django==4.2.5 from https://files.pythonhosted.org/packages/bf/8b/c38f2354b6093d9ba310a14b43a830fdf776edd60c2e25c7c5f4d23cc243/Django-4.2.5-py3-none-any.whl.metadata
[09:34:25.022] Downloading Django-4.2.5-py3-none-any.whl.metadata (4.1 kB)
[09:34:25.037] Collecting django-heroku==0.3.1 (from -r requirements.txt (line 10))
[09:34:25.051] Downloading django_heroku-0.3.1-py2.py3-none-any.whl (6.2 kB)
[09:34:25.083] Collecting filelock==3.12.4 (from -r requirements.txt (line 11))
[09:34:25.083] Obtaining dependency information for filelock==3.12.4 from https://files.pythonhosted.org/packages/5e/5d/97afbafd9d584ff1b45fcb354a479a3609bd97f912f8f1f6c563cb1fae21/filelock-3.12.4-py3-none-any.whl.metadata
[09:34:25.087] Downloading filelock-3.12.4-py3-none-any.whl.metadata (2.8 kB)
[09:34:25.200] Collecting fonttools==4.42.1 (from -r requirements.txt (line 12))
[09:34:25.200] Obtaining dependency information for fonttools==4.42.1 from https://files.pythonhosted.org/packages/49/50/2e31753c088d364756daa5bed0dab6a5928ebfd6e6d26f975c8b6d6f754a/fonttools-4.42.1-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.metadata
[09:34:25.206] Downloading fonttools-4.42.1-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.metadata (150 kB)
[09:34:25.211] ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 151.0/151.0 kB 54.3 MB/s eta 0:00:00
[09:34:25.243] Collecting gunicorn==21.2.0 (from -r requirements.txt (line 13))
[09:34:25.243] Obtaining dependency information for gunicorn==21.2.0 from https://files.pythonhosted.org/packages/0e/2a/c3a878eccb100ccddf45c50b6b8db8cf3301a6adede6e31d48e8531cab13/gunicorn-21.2.0-py3-none-any.whl.metadata
[09:34:25.247] Downloading gunicorn-21.2.0-py3-none-any.whl.metadata (4.1 kB)
[09:34:25.262] Collecting html5lib==1.1 (from -r requirements.txt (line 14))
[09:34:25.267] Downloading html5lib-1.1-py2.py3-none-any.whl (112 kB)
[09:34:25.271] ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 112.2/112.2 kB 59.7 MB/s eta 0:00:00
[09:34:25.303] Collecting packaging==23.1 (from -r requirements.txt (line 15))
[09:34:25.308] Downloading packaging-23.1-py3-none-any.whl (48 kB)
[09:34:25.312] ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 48.9/48.9 kB 28.9 MB/s eta 0:00:00
[09:34:25.327] Collecting pango==0.0.1 (from -r requirements.txt (line 16))
[09:34:25.332] Downloading pango-0.0.1.tar.gz (1.0 kB)
[09:34:25.340] Installing build dependencies: started
[09:34:26.795] Installing build dependencies: finished with status 'done'
[09:34:26.796] Getting requirements to build wheel: started
[09:34:27.020] Getting requirements to build wheel: finished with status 'done'
[09:34:27.023] Installing backend dependencies: started
[09:34:27.593] Installing backend dependencies: finished with status 'done'
[09:34:27.594] Preparing metadata (pyproject.toml): started
[09:34:27.825] Preparing metadata (pyproject.toml): finished with status 'done'
[09:34:28.162] Collecting Pillow==10.0.1 (from -r requirements.txt (line 17))
[09:34:28.162] Obtaining dependency information for Pillow==10.0.1 from https://files.pythonhosted.org/packages/5d/cc/3345b8cf6f2b8c5ee33d59e3e2ddb693c45c4f3c88e10859f8b8abf9dc82/Pillow-10.0.1-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.metadata
[09:34:28.167] Downloading Pillow-10.0.1-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.metadata (9.5 kB)
[09:34:28.279] Collecting pipenv==2023.9.8 (from -r requirements.txt (line 18))
[09:34:28.279] Obtaining dependency information for pipenv==2023.9.8 from https://files.pythonhosted.org/packages/a5/8b/60cf6828a57f05be72d0049cef7029b441c7e204aea0508d37fdf59a03f6/pipenv-2023.9.8-py3-none-any.whl.metadata
[09:34:28.283] Downloading pipenv-2023.9.8-py3-none-any.whl.metadata (15 kB)
[09:34:28.313] Collecting platformdirs==3.10.0 (from -r requirements.txt (line 19))
[09:34:28.314] Obtaining dependency information for platformdirs==3.10.0 from https://files.pythonhosted.org/packages/14/51/fe5a0d6ea589f0d4a1b97824fb518962ad48b27cd346dcdfa2405187997a/platformdirs-3.10.0-py3-none-any.whl.metadata
[09:34:28.318] Downloading platformdirs-3.10.0-py3-none-any.whl.metadata (11 kB)
[09:34:28.480] Collecting psycopg2-binary==2.9.8 (from -r requirements.txt (line 20))
[09:34:28.480] Obtaining dependency information for psycopg2-binary==2.9.8 from https://files.pythonhosted.org/packages/6a/cc/a9b6c7b135579f89493dbca86c8c12dece95fc4533d3180a7bc9fe87431f/psycopg2_binary-2.9.8-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.metadata
[09:34:28.487] Downloading psycopg2_binary-2.9.8-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.metadata (4.4 kB)
[09:34:28.502] Collecting pycparser==2.21 (from -r requirements.txt (line 21))
[09:34:28.506] Downloading pycparser-2.21-py2.py3-none-any.whl (118 kB)
[09:34:28.511] ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 118.7/118.7 kB 43.3 MB/s eta 0:00:00
[09:34:28.529] Collecting pydyf==0.8.0 (from -r requirements.txt (line 22))
[09:34:28.529] Obtaining dependency information for pydyf==0.8.0 from https://files.pythonhosted.org/packages/fd/d3/9e1a1b03a63c7314f9d2d413fb89d73459a3237f9cae6ca7f4107234bddf/pydyf-0.8.0-py3-none-any.whl.metadata
[09:34:28.537] Downloading pydyf-0.8.0-py3-none-any.whl.metadata (2.6 kB)
[09:34:28.553] Collecting pyphen==0.14.0 (from -r requirements.txt (line 23))
[09:34:28.562] Downloading pyphen-0.14.0-py3-none-any.whl (2.0 MB)
[09:34:28.581] ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 2.0/2.0 MB 116.6 MB/s eta 0:00:00
[09:34:28.601] Collecting python-decouple==3.8 (from -r requirements.txt (line 24))
[09:34:28.606] Downloading python_decouple-3.8-py3-none-any.whl (9.9 kB)
[09:34:28.626] Collecting six==1.16.0 (from -r requirements.txt (line 25))
[09:34:28.631] Downloading six-1.16.0-py2.py3-none-any.whl (11 kB)
[09:34:28.650] Collecting sqlparse==0.4.4 (from -r requirements.txt (line 26))
[09:34:28.655] Downloading sqlparse-0.4.4-py3-none-any.whl (41 kB)
[09:34:28.659] ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 41.2/41.2 kB 16.6 MB/s eta 0:00:00
[09:34:28.675] Collecting tinycss2==1.2.1 (from -r requirements.txt (line 27))
[09:34:28.679] Downloading tinycss2-1.2.1-py3-none-any.whl (21 kB)
[09:34:28.704] Collecting typing_extensions==4.8.0 (from -r requirements.txt (line 28))
[09:34:28.704] Obtaining dependency information for typing_extensions==4.8.0 from https://files.pythonhosted.org/packages/24/21/7d397a4b7934ff4028987914ac1044d3b7d52712f30e2ac7a2ae5bc86dd0/typing_extensions-4.8.0-py3-none-any.whl.metadata
[09:34:28.708] Downloading typing_extensions-4.8.0-py3-none-any.whl.metadata (3.0 kB)
[09:34:28.731] Collecting tzdata==2023.3 (from -r requirements.txt (line 29))
[09:34:28.736] Downloading tzdata-2023.3-py2.py3-none-any.whl (341 kB)
[09:34:28.742] ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 341.8/341.8 kB 99.0 MB/s eta 0:00:00
[09:34:28.760] Collecting validate-email==1.3 (from -r requirements.txt (line 30))
[09:34:28.768] Downloading validate_email-1.3.tar.gz (4.7 kB)
[09:34:28.776] Installing build dependencies: started
[09:34:30.187] Installing build dependencies: finished with status 'done'
[09:34:30.188] Getting requirements to build wheel: started
[09:34:30.347] Getting requirements to build wheel: finished with status 'done'
[09:34:30.351] Preparing metadata (pyproject.toml): started
[09:34:30.522] Preparing metadata (pyproject.toml): finished with status 'done'
[09:34:30.642] Collecting virtualenv==20.24.5 (from -r requirements.txt (line 31))
[09:34:30.642] Obtaining dependency information for virtualenv==20.24.5 from https://files.pythonhosted.org/packages/4e/8b/f0d3a468c0186c603217a6656ea4f49259630e8ed99558501d92f6ff7dc3/virtualenv-20.24.5-py3-none-any.whl.metadata
[09:34:30.647] Downloading virtualenv-20.24.5-py3-none-any.whl.metadata (4.5 kB)
[09:34:30.686] Collecting weasyprint==60.0 (from -r requirements.txt (line 32))
[09:34:30.687] Obtaining dependency information for weasyprint==60.0 from https://files.pythonhosted.org/packages/2b/e6/6f7b79551167611c59913a6222f0a57df10c4278ce30ec8d096158c3fa1c/weasyprint-60.0-py3-none-any.whl.metadata
[09:34:30.693] Downloading weasyprint-60.0-py3-none-any.whl.metadata (3.7 kB)
[09:34:30.706] Collecting webencodings==0.5.1 (from -r requirements.txt (line 33))
[09:34:30.710] Downloading webencodings-0.5.1-py2.py3-none-any.whl (11 kB)
[09:34:30.740] Collecting whitenoise==6.5.0 (from -r requirements.txt (line 34))
[09:34:30.741] Obtaining dependency information for whitenoise==6.5.0 from https://files.pythonhosted.org/packages/3f/d1/ab1d78bcf3e78517f4c57d34c3b349f1289afb5b2dbf46e5bf5c96932be5/whitenoise-6.5.0-py3-none-any.whl.metadata
[09:34:30.745] Downloading whitenoise-6.5.0-py3-none-any.whl.metadata (3.7 kB)
[09:34:30.761] Collecting xlwt==1.3.0 (from -r requirements.txt (line 35))
[09:34:30.765] Downloading xlwt-1.3.0-py2.py3-none-any.whl (99 kB)
[09:34:30.769] ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 100.0/100.0 kB 52.3 MB/s eta 0:00:00
[09:34:30.851] Collecting zopfli==0.2.3 (from -r requirements.txt (line 36))
[09:34:30.851] Obtaining dependency information for zopfli==0.2.3 from https://files.pythonhosted.org/packages/08/dd/9469d1e541ff0c0dcfd3369d746d8eafbb67820fb5a8102236f7260879d9/zopfli-0.2.3-cp39-cp39-manylinux_2_5_x86_64.manylinux1_x86_64.whl.metadata
[09:34:30.857] Downloading zopfli-0.2.3-cp39-cp39-manylinux_2_5_x86_64.manylinux1_x86_64.whl.metadata (2.9 kB)
[09:34:31.023] Collecting psycopg2 (from django-heroku==0.3.1->-r requirements.txt (line 10))
[09:34:31.031] Downloading psycopg2-2.9.8.tar.gz (383 kB)
[09:34:31.039] ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 383.8/383.8 kB 80.6 MB/s eta 0:00:00
[09:34:31.105] Installing build dependencies: started
[09:34:32.525] Installing build dependencies: finished with status 'done'
[09:34:32.526] Getting requirements to build wheel: started
[09:34:32.694] Getting requirements to build wheel: finished with status 'error'
[09:34:32.701] error: subprocess-exited-with-error
[09:34:32.702]   
[09:34:32.702] × Getting requirements to build wheel did not run successfully.
[09:34:32.702] │ exit code: 1
[09:34:32.702] ╰─> [21 lines of output]
[09:34:32.702] running egg_info
[09:34:32.702] writing psycopg2.egg-info/PKG-INFO
[09:34:32.702] writing dependency_links to psycopg2.egg-info/dependency_links.txt
[09:34:32.702] writing top-level names to psycopg2.egg-info/top_level.txt
[09:34:32.702]       
[09:34:32.702] Error: pg_config executable not found.
[09:34:32.702]       
[09:34:32.702] pg_config is required to build psycopg2 from source. Please add the directory
[09:34:32.702] containing pg_config to the $PATH or specify the full executable path with the
[09:34:32.702] option:
[09:34:32.702]       
[09:34:32.702] python setup.py build_ext --pg-config /path/to/pg_config build ...
[09:34:32.702]       
[09:34:32.702] or with the pg_config option in 'setup.cfg'.
[09:34:32.702]       
[09:34:32.702] If you prefer to avoid building psycopg2 from source, please install the PyPI
[09:34:32.702] 'psycopg2-binary' package instead.
[09:34:32.702]       
[09:34:32.702] For further information please check the 'doc/src/install.rst' file (also at
[09:34:32.702] <https://www.psycopg.org/docs/install.html>).
[09:34:32.703]       
[09:34:32.703] [end of output]
[09:34:32.703]   
[09:34:32.703] note: This error originates from a subprocess, and is likely not a problem with pip.
[09:34:32.704] error: subprocess-exited-with-error
[09:34:32.704] 
[09:34:32.704] × Getting requirements to build wheel did not run successfully.
[09:34:32.704] │ exit code: 1
[09:34:32.704] ╰─> See above for output.
[09:34:32.704] 
[09:34:32.704] note: This error originates from a subprocess, and is likely not a problem with pip.
[09:34:32.927] Error: Command "./build_files.sh" exited with 1

```

in my requirements.txt psycopg2-binary is present I am not able to understand the error here. Please help me

---

<div class="post-metadata">

**Author:** ![addwebsolution](https://sea2.discourse-cdn.com/flex026/user_avatar/forum.djangoproject.com/addwebsolution/32/23762_2.png) [@addwebsolution](https://forum.djangoproject.com/u/addwebsolution)\
**Post date:** [October 3, 2023, 5:31am UTC](https://forum.djangoproject.com/t/having-troubles-with-django-project-on-deployment-on-vercel/24269/2 "2023-10-03T05:31:02Z")

</div>

Can you share your `requirements.txt` file

---

<div class="post-metadata">

**Author:** ![csAfter40](https://sea2.discourse-cdn.com/flex026/user_avatar/forum.djangoproject.com/csafter40/32/15749_2.png) [@csAfter40](https://forum.djangoproject.com/u/csAfter40)\
**Post date:** [October 3, 2023, 9:27pm UTC](https://forum.djangoproject.com/t/having-troubles-with-django-project-on-deployment-on-vercel/24269/3 "2023-10-03T21:27:17Z")

</div>

Hi [theprateekgoyal2](https://forum.djangoproject.com/u/theprateekgoyal2),

I have an app running on vercel and I remember having a similar error during deployment. Please try removing “psycopg2” package from your requirements.txt file. Keep only “psycopg2-binary” package.

```auto
[09:34:31.023] Collecting psycopg2 (from django-heroku==0.3.1->-r requirements.txt (line 10))
[09:34:31.031] Downloading psycopg2-2.9.8.tar.gz (383 kB)

```

---

<div class="post-metadata">

**Author:** ![theprateekgoyal2](https://sea2.discourse-cdn.com/flex026/user_avatar/forum.djangoproject.com/theprateekgoyal2/32/16081_2.png) [@theprateekgoyal2](https://forum.djangoproject.com/u/theprateekgoyal2)\
**Post date:** [October 4, 2023, 4:13am UTC](https://forum.djangoproject.com/t/having-troubles-with-django-project-on-deployment-on-vercel/24269/5 "2023-10-04T04:13:43Z")

</div>

sure, here-

```auto
asgiref==3.7.2
Brotli==1.1.0
certifi==2023.7.22
cffi==1.15.1
cssselect2==0.7.0
dirtree==0.3.0.dev0
distlib==0.3.7
dj-database-url==2.1.0
Django==4.2.5
django-heroku==0.3.1
filelock==3.12.4
fonttools==4.42.1
gunicorn==21.2.0
html5lib==1.1
packaging==23.1
pango==0.0.1
Pillow==10.0.1
pipenv==2023.9.8
platformdirs==3.10.0
psycopg2==2.9.7
psycopg2-binary==2.9.8
pycparser==2.21
pydyf==0.8.0
pyphen==0.14.0
python-decouple==3.8
six==1.16.0
sqlparse==0.4.4
tinycss2==1.2.1
typing_extensions==4.8.0
tzdata==2023.3
validate-email==1.3
virtualenv==20.24.5
weasyprint==60.0
webencodings==0.5.1
whitenoise==6.5.0
xlwt==1.3.0
zopfli==0.2.3

```

---

<div class="post-metadata">

**Author:** ![theprateekgoyal2](https://sea2.discourse-cdn.com/flex026/user_avatar/forum.djangoproject.com/theprateekgoyal2/32/16081_2.png) [@theprateekgoyal2](https://forum.djangoproject.com/u/theprateekgoyal2)\
**Post date:** [October 4, 2023, 4:14am UTC](https://forum.djangoproject.com/t/having-troubles-with-django-project-on-deployment-on-vercel/24269/6 "2023-10-04T04:14:41Z")

</div>

Thanks for reverting. I have tried it both ways, keeping the psycopg2 package and even removing it. But it gives me the same error message. I can share the requirements.txt file if that may help-

```auto
asgiref==3.7.2
Brotli==1.1.0
certifi==2023.7.22
cffi==1.15.1
cssselect2==0.7.0
dirtree==0.3.0.dev0
distlib==0.3.7
dj-database-url==2.1.0
Django==4.2.5
django-heroku==0.3.1
filelock==3.12.4
fonttools==4.42.1
gunicorn==21.2.0
html5lib==1.1
packaging==23.1
pango==0.0.1
Pillow==10.0.1
pipenv==2023.9.8
platformdirs==3.10.0
psycopg2==2.9.7
psycopg2-binary==2.9.8
pycparser==2.21
pydyf==0.8.0
pyphen==0.14.0
python-decouple==3.8
six==1.16.0
sqlparse==0.4.4
tinycss2==1.2.1
typing_extensions==4.8.0
tzdata==2023.3
validate-email==1.3
virtualenv==20.24.5
weasyprint==60.0
webencodings==0.5.1
whitenoise==6.5.0
xlwt==1.3.0
zopfli==0.2.3

```

---

<div class="post-metadata">

**Author:** ![addwebsolution](https://sea2.discourse-cdn.com/flex026/user_avatar/forum.djangoproject.com/addwebsolution/32/23762_2.png) [@addwebsolution](https://forum.djangoproject.com/u/addwebsolution)\
**Post date:** [October 4, 2023, 4:40am UTC](https://forum.djangoproject.com/t/having-troubles-with-django-project-on-deployment-on-vercel/24269/7 "2023-10-04T04:40:26Z")

</div>

> [@theprateekgoyal2](#):
>
> ```auto
> psycopg2==2.9.7
> psycopg2-binary==2.9.8
> 
> ```

From you requirements.txt remove this `psycopg2==2.9.7` only `psycopg2-binary==2.9.8` is all you need.

---

<div class="post-metadata">

**Author:** ![dennisvd](https://sea2.discourse-cdn.com/flex026/user_avatar/forum.djangoproject.com/dennisvd/32/1441_2.png) [@dennisvd](https://forum.djangoproject.com/u/dennisvd)\
**Post date:** [October 4, 2023, 5:17am UTC](https://forum.djangoproject.com/t/having-troubles-with-django-project-on-deployment-on-vercel/24269/8 "2023-10-04T05:17:54Z")

</div>

If I remember correctly Vercel is a serverless hosting platform. Django can work on it but platforms like Django are not well suited for serverless. Unless perhaps you only use Django Rest Framework and no frontend but even then my advice would be to find another hosting partner.

---

<div class="post-metadata">

**Author:** ![theprateekgoyal2](https://sea2.discourse-cdn.com/flex026/user_avatar/forum.djangoproject.com/theprateekgoyal2/32/16081_2.png) [@theprateekgoyal2](https://forum.djangoproject.com/u/theprateekgoyal2)\
**Post date:** [October 4, 2023, 7:34am UTC](https://forum.djangoproject.com/t/having-troubles-with-django-project-on-deployment-on-vercel/24269/9 "2023-10-04T07:34:52Z")

</div>

can you suggest me a free one? That’d be very helpful. Heroku is paid now.

---

<div class="post-metadata">

**Author:** ![addwebsolution](https://sea2.discourse-cdn.com/flex026/user_avatar/forum.djangoproject.com/addwebsolution/32/23762_2.png) [@addwebsolution](https://forum.djangoproject.com/u/addwebsolution)\
**Post date:** [October 4, 2023, 7:47am UTC](https://forum.djangoproject.com/t/having-troubles-with-django-project-on-deployment-on-vercel/24269/10 "2023-10-04T07:47:37Z")

</div>

Well there are many, even Digital Ocean which is popular cloud service also provide you $200 Credits which is enough to try all the services to use for 2 months after that it starts charging for the services.  
PythonAnywhere is also one of the good option to try.

---

<div class="post-metadata">

**Author:** ![theprateekgoyal2](https://sea2.discourse-cdn.com/flex026/user_avatar/forum.djangoproject.com/theprateekgoyal2/32/16081_2.png) [@theprateekgoyal2](https://forum.djangoproject.com/u/theprateekgoyal2)\
**Post date:** [October 4, 2023, 7:50am UTC](https://forum.djangoproject.com/t/having-troubles-with-django-project-on-deployment-on-vercel/24269/11 "2023-10-04T07:50:23Z")

</div>

I checked digital ocean and python anywhere. But in digital ocean its paid, and right now I cant afford to buy it. and python anywhere supports python 3.9 my project is 3.11 and also it failed in my case maybe because I did something wrong. if there is any good tutorial can you share that?

---

<div class="post-metadata">

**Author:** ![theprateekgoyal2](https://sea2.discourse-cdn.com/flex026/user_avatar/forum.djangoproject.com/theprateekgoyal2/32/16081_2.png) [@theprateekgoyal2](https://forum.djangoproject.com/u/theprateekgoyal2)\
**Post date:** [October 4, 2023, 7:50am UTC](https://forum.djangoproject.com/t/having-troubles-with-django-project-on-deployment-on-vercel/24269/12 "2023-10-04T07:50:53Z")

</div>

still its giving me the error -

````auto
[09:34:21.181] Running build in Washington, D.C., USA (East) – iad1 (Hive)
[09:34:21.285] Cloning github.com/theprateekgoyal2/expenseswebsite (Branch: main, Commit: ecfdf0a)
[09:34:21.624] Previous build cache not available
[09:34:21.767] Cloning completed: 481.175ms
[09:34:22.107] Running "vercel build"
[09:34:22.554] Vercel CLI 32.3.1
[09:34:22.706] WARN! Due to `builds` existing in your configuration file, the Build and Development Settings defined in your Project Settings will not apply. Learn More: https://vercel.link/unused-build-settings
[09:34:24.436] Collecting asgiref==3.7.2 (from -r requirements.txt (line 1))
[09:34:24.436] Obtaining dependency information for asgiref==3.7.2 from https://files.pythonhosted.org/packages/9b/80/b9051a4a07ad231558fcd8ffc89232711b4e618c15cb7a392a17384bbeef/asgiref-3.7.2-py3-none-any.whl.metadata
[09:34:24.459] Downloading asgiref-3.7.2-py3-none-any.whl.metadata (9.2 kB)
[09:34:24.520] Collecting Brotli==1.1.0 (from -r requirements.txt (line 2))
[09:34:24.520] Obtaining dependency information for Brotli==1.1.0 from https://files.pythonhosted.org/packages/e2/e6/4a730f6e5b5d538e92d09bc51bf69119914f29a222f9e1d65ae4abb27a4e/Brotli-1.1.0-cp39-cp39-manylinux_2_5_x86_64.manylinux1_x86_64.whl.metadata
[09:34:24.525] Downloading Brotli-1.1.0-cp39-cp39-manylinux_2_5_x86_64.manylinux1_x86_64.whl.metadata (5.5 kB)
[09:34:24.556] Collecting certifi==2023.7.22 (from -r requirements.txt (line 3))
[09:34:24.557] Obtaining dependency information for certifi==2023.7.22 from https://files.pythonhosted.org/packages/4c/dd/2234eab22353ffc7d94e8d13177aaa050113286e93e7b40eae01fbf7c3d9/certifi-2023.7.22-py3-none-any.whl.metadata
[09:34:24.561] Downloading certifi-2023.7.22-py3-none-any.whl.metadata (2.2 kB)
[09:34:24.796] Collecting cffi==1.15.1 (from -r requirements.txt (line 4))
[09:34:24.800] Downloading cffi-1.15.1-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (441 kB)
[09:34:24.812] ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 441.2/441.2 kB 47.3 MB/s eta 0:00:00
[09:34:24.837] Collecting cssselect2==0.7.0 (from -r requirements.txt (line 5))
[09:34:24.841] Downloading cssselect2-0.7.0-py3-none-any.whl (15 kB)
[09:34:24.854] Collecting dirtree==0.3.0.dev0 (from -r requirements.txt (line 6))
[09:34:24.859] Downloading dirtree-0.3.0.dev0-py3-none-any.whl (3.7 kB)
[09:34:24.877] Collecting distlib==0.3.7 (from -r requirements.txt (line 7))
[09:34:24.877] Obtaining dependency information for distlib==0.3.7 from https://files.pythonhosted.org/packages/43/a0/9ba967fdbd55293bacfc1507f58e316f740a3b231fc00e3d86dc39bc185a/distlib-0.3.7-py2.py3-none-any.whl.metadata
[09:34:24.881] Downloading distlib-0.3.7-py2.py3-none-any.whl.metadata (5.1 kB)
[09:34:24.897] Collecting dj-database-url==2.1.0 (from -r requirements.txt (line 8))
[09:34:24.897] Obtaining dependency information for dj-database-url==2.1.0 from https://files.pythonhosted.org/packages/21/d2/b90366de4682c1472748b848292054e0960673f3c7d1a9d08fb227fad819/dj_database_url-2.1.0-py3-none-any.whl.metadata
[09:34:24.901] Downloading dj_database_url-2.1.0-py3-none-any.whl.metadata (11 kB)
[09:34:25.017] Collecting Django==4.2.5 (from -r requirements.txt (line 9))
[09:34:25.018] Obtaining dependency information for Django==4.2.5 from https://files.pythonhosted.org/packages/bf/8b/c38f2354b6093d9ba310a14b43a830fdf776edd60c2e25c7c5f4d23cc243/Django-4.2.5-py3-none-any.whl.metadata
[09:34:25.022] Downloading Django-4.2.5-py3-none-any.whl.metadata (4.1 kB)
[09:34:25.037] Collecting django-heroku==0.3.1 (from -r requirements.txt (line 10))
[09:34:25.051] Downloading django_heroku-0.3.1-py2.py3-none-any.whl (6.2 kB)
[09:34:25.083] Collecting filelock==3.12.4 (from -r requirements.txt (line 11))
[09:34:25.083] Obtaining dependency information for filelock==3.12.4 from https://files.pythonhosted.org/packages/5e/5d/97afbafd9d584ff1b45fcb354a479a3609bd97f912f8f1f6c563cb1fae21/filelock-3.12.4-py3-none-any.whl.metadata
[09:34:25.087] Downloading filelock-3.12.4-py3-none-any.whl.metadata (2.8 kB)
[09:34:25.200] Collecting fonttools==4.42.1 (from -r requirements.txt (line 12))
[09:34:25.200] Obtaining dependency information for fonttools==4.42.1 from https://files.pythonhosted.org/packages/49/50/2e31753c088d364756daa5bed0dab6a5928ebfd6e6d26f975c8b6d6f754a/fonttools-4.42.1-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.metadata
[09:34:25.206] Downloading fonttools-4.42.1-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.metadata (150 kB)
[09:34:25.211] ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 151.0/151.0 kB 54.3 MB/s eta 0:00:00
[09:34:25.243] Collecting gunicorn==21.2.0 (from -r requirements.txt (line 13))
[09:34:25.243] Obtaining dependency information for gunicorn==21.2.0 from https://files.pythonhosted.org/packages/0e/2a/c3a878eccb100ccddf45c50b6b8db8cf3301a6adede6e31d48e8531cab13/gunicorn-21.2.0-py3-none-any.whl.metadata
[09:34:25.247] Downloading gunicorn-21.2.0-py3-none-any.whl.metadata (4.1 kB)
[09:34:25.262] Collecting html5lib==1.1 (from -r requirements.txt (line 14))
[09:34:25.267] Downloading html5lib-1.1-py2.py3-none-any.whl (112 kB)
[09:34:25.271] ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 112.2/112.2 kB 59.7 MB/s eta 0:00:00
[09:34:25.303] Collecting packaging==23.1 (from -r requirements.txt (line 15))
[09:34:25.308] Downloading packaging-23.1-py3-none-any.whl (48 kB)
[09:34:25.312] ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 48.9/48.9 kB 28.9 MB/s eta 0:00:00
[09:34:25.327] Collecting pango==0.0.1 (from -r requirements.txt (line 16))
[09:34:25.332] Downloading pango-0.0.1.tar.gz (1.0 kB)
[09:34:25.340] Installing build dependencies: started
[09:34:26.795] Installing build dependencies: finished with status 'done'
[09:34:26.796] Getting requirements to build wheel: started
[09:34:27.020] Getting requirements to build wheel: finished with status 'done'
[09:34:27.023] Installing backend dependencies: started
[09:34:27.593] Installing backend dependencies: finished with status 'done'
[09:34:27.594] Preparing metadata (pyproject.toml): started
[09:34:27.825] Preparing metadata (pyproject.toml): finished with status 'done'
[09:34:28.162] Collecting Pillow==10.0.1 (from -r requirements.txt (line 17))
[09:34:28.162] Obtaining dependency information for Pillow==10.0.1 from https://files.pythonhosted.org/packages/5d/cc/3345b8cf6f2b8c5ee33d59e3e2ddb693c45c4f3c88e10859f8b8abf9dc82/Pillow-10.0.1-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.metadata
[09:34:28.167] Downloading Pillow-10.0.1-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.metadata (9.5 kB)
[09:34:28.279] Collecting pipenv==2023.9.8 (from -r requirements.txt (line 18))
[09:34:28.279] Obtaining dependency information for pipenv==2023.9.8 from https://files.pythonhosted.org/packages/a5/8b/60cf6828a57f05be72d0049cef7029b441c7e204aea0508d37fdf59a03f6/pipenv-2023.9.8-py3-none-any.whl.metadata
[09:34:28.283] Downloading pipenv-2023.9.8-py3-none-any.whl.metadata (15 kB)
[09:34:28.313] Collecting platformdirs==3.10.0 (from -r requirements.txt (line 19))
[09:34:28.314] Obtaining dependency information for platformdirs==3.10.0 from https://files.pythonhosted.org/packages/14/51/fe5a0d6ea589f0d4a1b97824fb518962ad48b27cd346dcdfa2405187997a/platformdirs-3.10.0-py3-none-any.whl.metadata
[09:34:28.318] Downloading platformdirs-3.10.0-py3-none-any.whl.metadata (11 kB)
[09:34:28.480] Collecting psycopg2-binary==2.9.8 (from -r requirements.txt (line 20))
[09:34:28.480] Obtaining dependency information for psycopg2-binary==2.9.8 from https://files.pythonhosted.org/packages/6a/cc/a9b6c7b135579f89493dbca86c8c12dece95fc4533d3180a7bc9fe87431f/psycopg2_binary-2.9.8-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.metadata
[09:34:28.487] Downloading psycopg2_binary-2.9.8-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.metadata (4.4 kB)
[09:34:28.502] Collecting pycparser==2.21 (from -r requirements.txt (line 21))
[09:34:28.506] Downloading pycparser-2.21-py2.py3-none-any.whl (118 kB)
[09:34:28.511] ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 118.7/118.7 kB 43.3 MB/s eta 0:00:00
[09:34:28.529] Collecting pydyf==0.8.0 (from -r requirements.txt (line 22))
[09:34:28.529] Obtaining dependency information for pydyf==0.8.0 from https://files.pythonhosted.org/packages/fd/d3/9e1a1b03a63c7314f9d2d413fb89d73459a3237f9cae6ca7f4107234bddf/pydyf-0.8.0-py3-none-any.whl.metadata
[09:34:28.537] Downloading pydyf-0.8.0-py3-none-any.whl.metadata (2.6 kB)
[09:34:28.553] Collecting pyphen==0.14.0 (from -r requirements.txt (line 23))
[09:34:28.562] Downloading pyphen-0.14.0-py3-none-any.whl (2.0 MB)
[09:34:28.581] ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 2.0/2.0 MB 116.6 MB/s eta 0:00:00
[09:34:28.601] Collecting python-decouple==3.8 (from -r requirements.txt (line 24))
[09:34:28.606] Downloading python_decouple-3.8-py3-none-any.whl (9.9 kB)
[09:34:28.626] Collecting six==1.16.0 (from -r requirements.txt (line 25))
[09:34:28.631] Downloading six-1.16.0-py2.py3-none-any.whl (11 kB)
[09:34:28.650] Collecting sqlparse==0.4.4 (from -r requirements.txt (line 26))
[09:34:28.655] Downloading sqlparse-0.4.4-py3-none-any.whl (41 kB)
[09:34:28.659] ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 41.2/41.2 kB 16.6 MB/s eta 0:00:00
[09:34:28.675] Collecting tinycss2==1.2.1 (from -r requirements.txt (line 27))
[09:34:28.679] Downloading tinycss2-1.2.1-py3-none-any.whl (21 kB)
[09:34:28.704] Collecting typing_extensions==4.8.0 (from -r requirements.txt (line 28))
[09:34:28.704] Obtaining dependency information for typing_extensions==4.8.0 from https://files.pythonhosted.org/packages/24/21/7d397a4b7934ff4028987914ac1044d3b7d52712f30e2ac7a2ae5bc86dd0/typing_extensions-4.8.0-py3-none-any.whl.metadata
[09:34:28.708] Downloading typing_extensions-4.8.0-py3-none-any.whl.metadata (3.0 kB)
[09:34:28.731] Collecting tzdata==2023.3 (from -r requirements.txt (line 29))
[09:34:28.736] Downloading tzdata-2023.3-py2.py3-none-any.whl (341 kB)
[09:34:28.742] ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 341.8/341.8 kB 99.0 MB/s eta 0:00:00
[09:34:28.760] Collecting validate-email==1.3 (from -r requirements.txt (line 30))
[09:34:28.768] Downloading validate_email-1.3.tar.gz (4.7 kB)
[09:34:28.776] Installing build dependencies: started
[09:34:30.187] Installing build dependencies: finished with status 'done'
[09:34:30.188] Getting requirements to build wheel: started
[09:34:30.347] Getting requirements to build wheel: finished with status 'done'
[09:34:30.351] Preparing metadata (pyproject.toml): started
[09:34:30.522] Preparing metadata (pyproject.toml): finished with status 'done'
[09:34:30.642] Collecting virtualenv==20.24.5 (from -r requirements.txt (line 31))
[09:34:30.642] Obtaining dependency information for virtualenv==20.24.5 from https://files.pythonhosted.org/packages/4e/8b/f0d3a468c0186c603217a6656ea4f49259630e8ed99558501d92f6ff7dc3/virtualenv-20.24.5-py3-none-any.whl.metadata
[09:34:30.647] Downloading virtualenv-20.24.5-py3-none-any.whl.metadata (4.5 kB)
[09:34:30.686] Collecting weasyprint==60.0 (from -r requirements.txt (line 32))
[09:34:30.687] Obtaining dependency information for weasyprint==60.0 from https://files.pythonhosted.org/packages/2b/e6/6f7b79551167611c59913a6222f0a57df10c4278ce30ec8d096158c3fa1c/weasyprint-60.0-py3-none-any.whl.metadata
[09:34:30.693] Downloading weasyprint-60.0-py3-none-any.whl.metadata (3.7 kB)
[09:34:30.706] Collecting webencodings==0.5.1 (from -r requirements.txt (line 33))
[09:34:30.710] Downloading webencodings-0.5.1-py2.py3-none-any.whl (11 kB)
[09:34:30.740] Collecting whitenoise==6.5.0 (from -r requirements.txt (line 34))
[09:34:30.741] Obtaining dependency information for whitenoise==6.5.0 from https://files.pythonhosted.org/packages/3f/d1/ab1d78bcf3e78517f4c57d34c3b349f1289afb5b2dbf46e5bf5c96932be5/whitenoise-6.5.0-py3-none-any.whl.metadata
[09:34:30.745] Downloading whitenoise-6.5.0-py3-none-any.whl.metadata (3.7 kB)
[09:34:30.761] Collecting xlwt==1.3.0 (from -r requirements.txt (line 35))
[09:34:30.765] Downloading xlwt-1.3.0-py2.py3-none-any.whl (99 kB)
[09:34:30.769] ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 100.0/100.0 kB 52.3 MB/s eta 0:00:00
[09:34:30.851] Collecting zopfli==0.2.3 (from -r requirements.txt (line 36))
[09:34:30.851] Obtaining dependency information for zopfli==0.2.3 from https://files.pythonhosted.org/packages/08/dd/9469d1e541ff0c0dcfd3369d746d8eafbb67820fb5a8102236f7260879d9/zopfli-0.2.3-cp39-cp39-manylinux_2_5_x86_64.manylinux1_x86_64.whl.metadata
[09:34:30.857] Downloading zopfli-0.2.3-cp39-cp39-manylinux_2_5_x86_64.manylinux1_x86_64.whl.metadata (2.9 kB)
[09:34:31.023] Collecting psycopg2 (from django-heroku==0.3.1->-r requirements.txt (line 10))
[09:34:31.031] Downloading psycopg2-2.9.8.tar.gz (383 kB)
[09:34:31.039] ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 383.8/383.8 kB 80.6 MB/s eta 0:00:00
[09:34:31.105] Installing build dependencies: started
[09:34:32.525] Installing build dependencies: finished with status 'done'
[09:34:32.526] Getting requirements to build wheel: started
[09:34:32.694] Getting requirements to build wheel: finished with status 'error'
[09:34:32.701] error: subprocess-exited-with-error
[09:34:32.702]   
[09:34:32.702] × Getting requirements to build wheel did not run successfully.
[09:34:32.702] │ exit code: 1
[09:34:32.702] ╰─> [21 lines of output]
[09:34:32.702] running egg_info
[09:34:32.702] writing psycopg2.egg-info/PKG-INFO
[09:34:32.702] writing dependency_links to psycopg2.egg-info/dependency_links.txt
[09:34:32.702] writing top-level names to psycopg2.egg-info/top_level.txt
[09:34:32.702]       
[09:34:32.702] Error: pg_config executable not found.
[09:34:32.702]       
[09:34:32.702] pg_config is required to build psycopg2 from source. Please add the directory
[09:34:32.702] containing pg_config to the $PATH or specify the full executable path with the
[09:34:32.702] option:
[09:34:32.702]       
[09:34:32.702] python setup.py build_ext --pg-config /path/to/pg_config build ...
[09:34:32.702]       
[09:34:32.702] or with the pg_config option in 'setup.cfg'.
[09:34:32.702]       
[09:34:32.702] If you prefer to avoid building psycopg2 from source, please install the PyPI
[09:34:32.702] 'psycopg2-binary' package instead.
[09:34:32.702]       
[09:34:32.702] For further information please check the 'doc/src/install.rst' file (also at
[09:34:32.702] <https://www.psycopg.org/docs/install.html>).
[09:34:32.703]       
[09:34:32.703] [end of output]
[09:34:32.703]   
[09:34:32.703] note: This error originates from a subprocess, and is likely not a problem with pip.
[09:34:32.704] error: subprocess-exited-with-error
[09:34:32.704] 
[09:34:32.704] × Getting requirements to build wheel did not run successfully.
[09:34:32.704] │ exit code: 1
[09:34:32.704] ╰─> See above for output.
[09:34:32.704] 
[09:34:32.704] note: This error originates from a subprocess, and is likely not a problem with pip.
[09:34:32.927] Error: Command "./build_files.sh" exited with 1```
````

---

<div class="post-metadata">

**Author:** ![addwebsolution](https://sea2.discourse-cdn.com/flex026/user_avatar/forum.djangoproject.com/addwebsolution/32/23762_2.png) [@addwebsolution](https://forum.djangoproject.com/u/addwebsolution)\
**Post date:** [October 4, 2023, 7:52am UTC](https://forum.djangoproject.com/t/having-troubles-with-django-project-on-deployment-on-vercel/24269/13 "2023-10-04T07:52:11Z")

</div>

This error persist because of this.

> [@addwebsolution](#):
>
> From you requirements.txt remove this `psycopg2==2.9.7` only `psycopg2-binary==2.9.8` is all you need.

I’ve already told you about this in previous post.

---

<div class="post-metadata">

**Author:** ![theprateekgoyal2](https://sea2.discourse-cdn.com/flex026/user_avatar/forum.djangoproject.com/theprateekgoyal2/32/16081_2.png) [@theprateekgoyal2](https://forum.djangoproject.com/u/theprateekgoyal2)\
**Post date:** [October 4, 2023, 8:26am UTC](https://forum.djangoproject.com/t/having-troubles-with-django-project-on-deployment-on-vercel/24269/14 "2023-10-04T08:26:53Z")

</div>

```auto
asgiref==3.7.2
Brotli==1.1.0
certifi==2023.7.22
cffi==1.15.1
cssselect2==0.7.0
dirtree==0.3.0.dev0
distlib==0.3.7
dj-database-url==2.1.0
Django==4.2.5
django-heroku==0.3.1
filelock==3.12.4
fonttools==4.42.1
gunicorn==21.2.0
html5lib==1.1
packaging==23.1
pango==0.0.1
Pillow==10.0.1
pipenv==2023.9.8
platformdirs==3.10.0
psycopg2-binary==2.9.8
pycparser==2.21
pydyf==0.8.0
pyphen==0.14.0
python-decouple==3.8
six==1.16.0
sqlparse==0.4.4
tinycss2==1.2.1
typing_extensions==4.8.0
tzdata==2023.3
validate-email==1.3
virtualenv==20.24.5
weasyprint==60.0
webencodings==0.5.1
whitenoise==6.5.0
xlwt==1.3.0
zopfli==0.2.3

```

the requirements.txt file in the GitHub repository. Here I have removed this

```auto
psycopg2==2.9.7

```

but on GitHub its showing this, maybe that can be an error -

 ![image](https://us1.discourse-cdn.com/flex026/uploads/djangoproject/original/3X/6/c/6cca7b32e428d4332704937a1ae0acb115d0aef4.png)

---

<div class="post-metadata">

**Author:** ![dennisvd](https://sea2.discourse-cdn.com/flex026/user_avatar/forum.djangoproject.com/dennisvd/32/1441_2.png) [@dennisvd](https://forum.djangoproject.com/u/dennisvd)\
**Post date:** [October 4, 2023, 9:25am UTC](https://forum.djangoproject.com/t/having-troubles-with-django-project-on-deployment-on-vercel/24269/15 "2023-10-04T09:25:28Z")

</div>

For a system that needs to run in production there is no good free option. For development and testing you can run it locally on your own machine and you could use a service like ngrok to expose your server to the internet.

---

<div class="post-metadata">

**Author:** ![theprateekgoyal2](https://sea2.discourse-cdn.com/flex026/user_avatar/forum.djangoproject.com/theprateekgoyal2/32/16081_2.png) [@theprateekgoyal2](https://forum.djangoproject.com/u/theprateekgoyal2)\
**Post date:** [October 4, 2023, 10:51am UTC](https://forum.djangoproject.com/t/having-troubles-with-django-project-on-deployment-on-vercel/24269/16 "2023-10-04T10:51:54Z")

</div>

Hey, my project deployed successfully on Vercel. but there is still an issue with static files. The path and all are all correct but I don’t know why it says file not found 404.

this is the console view-

 ![image](https://us1.discourse-cdn.com/flex026/uploads/djangoproject/original/3X/f/9/f97fa70c23c04c20a24b877fcf2011f0f2895c6d.png)

and this the part of settings.py file which contains static root -

```auto
STATIC_URL = '/static/'
# STATICFILES_DIRS = [
# os.path.join(BASE_DIR, 'expenseswebsite', 'static'),
# ]
STATIC_ROOT = os.path.join(BASE_DIR, 'static')
# print(STATIC_ROOT)

```

the project structure-

````auto
├───.vscode
├───authentication
│ ├───migrations
│ │ └─── __pycache__
│ └─── __pycache__
├───dashboard
│ ├───migrations
│ │ └─── __pycache__
│ └─── __pycache__
├───expenses
│ ├───migrations
│ │ └─── __pycache__
│ └─── __pycache__
├───expenseswebsite
│ ├───static
│ │ ├───css
│ │ ├───img
│ │ └───js
│ └─── __pycache__
├───static
│ ├───admin
│ │ ├───css
│ │ │ └───vendor
│ │ │ └───select2
│ │ ├───img
│ │ │ └───gis
│ │ └───js
│ │ ├───admin
│ │ └───vendor
│ │ ├───jquery
│ │ ├───select2
│ │ │ └───i18n
│ │ └───xregexp
│ ├───css
│ ├───img
│ └───js
├───templates
│ ├───admin
│ ├───authentication
│ ├───dashboard
│ ├───expenses
│ ├───income
│ ├───partials
│ └───userprefernces
├───userincome
│ ├───migrations
│ │ └─── __pycache__
│ └─── __pycache__
└───userprefernces
    ├───migrations
    │ └─── __pycache__
    └─── __pycache__ ```
````

---

<div class="post-metadata">

**Author:** ![theprateekgoyal2](https://sea2.discourse-cdn.com/flex026/user_avatar/forum.djangoproject.com/theprateekgoyal2/32/16081_2.png) [@theprateekgoyal2](https://forum.djangoproject.com/u/theprateekgoyal2)\
**Post date:** [October 4, 2023, 10:54am UTC](https://forum.djangoproject.com/t/having-troubles-with-django-project-on-deployment-on-vercel/24269/17 "2023-10-04T10:54:07Z")

</div>

Hey man thanks I needed to remove one more line then it deployed successfully but I still have one more issue for the static files. can see my reply to - csAfter40  
in this thread?

---

<div class="post-metadata">

**Author:** ![addwebsolution](https://sea2.discourse-cdn.com/flex026/user_avatar/forum.djangoproject.com/addwebsolution/32/23762_2.png) [@addwebsolution](https://forum.djangoproject.com/u/addwebsolution)\
**Post date:** [October 4, 2023, 10:59am UTC](https://forum.djangoproject.com/t/having-troubles-with-django-project-on-deployment-on-vercel/24269/18 "2023-10-04T10:59:45Z")

</div>

Did you run `manage.py collectstatic` command?

Also in your root urls.py update code according to this sample below

```auto
from django.contrib import admin
from django.urls import path, include
from django.conf.urls.static import static
from django.conf import settings

urlpatterns = [
    ...
] + static(settings.MEDIA_URL, document_root=settings.MEDIA_ROOT) + static(settings.STATIC_URL, document_root=settings.STATIC_ROOT)

```

---

<div class="post-metadata">

**Author:** ![theprateekgoyal2](https://sea2.discourse-cdn.com/flex026/user_avatar/forum.djangoproject.com/theprateekgoyal2/32/16081_2.png) [@theprateekgoyal2](https://forum.djangoproject.com/u/theprateekgoyal2)\
**Post date:** [October 4, 2023, 11:01am UTC](https://forum.djangoproject.com/t/having-troubles-with-django-project-on-deployment-on-vercel/24269/19 "2023-10-04T11:01:46Z")

</div>

yes I have run collectstatic command and also this line is in present in my root urls.py

```auto

urlpatterns += static(settings.STATIC_URL, document_root=settings.STATIC_ROOT)

```

---

<div class="post-metadata">

**Author:** ![addwebsolution](https://sea2.discourse-cdn.com/flex026/user_avatar/forum.djangoproject.com/addwebsolution/32/23762_2.png) [@addwebsolution](https://forum.djangoproject.com/u/addwebsolution)\
**Post date:** [October 4, 2023, 11:03am UTC](https://forum.djangoproject.com/t/having-troubles-with-django-project-on-deployment-on-vercel/24269/20 "2023-10-04T11:03:51Z")

</div>

So all of the static files are not being loaded or some specific files?

---

<div class="post-metadata">

**Author:** ![theprateekgoyal2](https://sea2.discourse-cdn.com/flex026/user_avatar/forum.djangoproject.com/theprateekgoyal2/32/16081_2.png) [@theprateekgoyal2](https://forum.djangoproject.com/u/theprateekgoyal2)\
**Post date:** [October 4, 2023, 11:06am UTC](https://forum.djangoproject.com/t/having-troubles-with-django-project-on-deployment-on-vercel/24269/21 "2023-10-04T11:06:57Z")

</div>

all files are not opening

[Next page](https://forum.djangoproject.com/t/having-troubles-with-django-project-on-deployment-on-vercel/24269.md?page=2)
