vercel: Vercel deploy fails, reason: socket hang up
Vercel CLI failed while trying to deploy the app.
Even though the app continue to build and deploy on vercel, with a sequence of staging deploys queue.
Command:
npx vercel
Output:
Vercel CLI 23.1.2
Error! request to https://api.vercel.com/v13/now/deployments?teamId=team_*** failed, reason: socket hang up
Result:

Expected: no errors, 1 deploy.
Platform: Linux Vercel CLI version: 23.1.2
About this issue
- Original URL
- State: closed
- Created 3 years ago
- Comments: 20 (1 by maintainers)
Here is part of the response I got from Vercel regarding the aforementioned error:
I was not able to identify any such large folders or internet issues, so I tried what @GiancarlosIO proposed by adding --archive=tgz and it worked! Here is what our uploading script looks like:
I’m also experiencing this issue with Vercel CLI 25.1.0.
@ivstiv I was getting the same error. To fix that I switched to
vercel deploy --prebuilt --archive=tgzNow, we run the following commands in our gitlab runner to deploy our nextjs apps:vercel pullvercel buildvercel deploy --prebuilt --archive=tgzRelated discussion: https://github.com/vercel/vercel/discussions/8643
I’m having the exact same issue, it hangs for a while and then errors out with failed, reason: socket hang up. Anyone found a fix?
Hi @GiancarlosIO @TooTallNate. I did not do anything, It just simply started working as it should after a few days… 😅
I turned on the VPN and everything worked
Why the option
--archive=tgzoption is not on Vercel’s CLI help? 🤔hi @vinisaveg @TooTallNate, How did u solve that error? I’m getting the same error For some reason the command
vercel -t my-tokenfails with afailed, reason: socket hang up. This error happens in our GitLab ci (and also in local). The other thing is that I don’t get why 6-7 deployments are created when we runvercel -t my-tokenonly one time.