# GitHub Push overwrites vercel.json and workflows

**URL:** https://community.weweb.io/t/github-push-overwrites-vercel-json-and-workflows/19844
**Category:** Developer corner
**Created:** [September 2, 2025, 8:29am UTC](https://community.weweb.io/t/github-push-overwrites-vercel-json-and-workflows/19844 "2025-09-02T08:29:24Z")
**Posts on this page:** 6
**Page:** 1

<div class="post-metadata">

### Author: ![fynn](https://sea2.discourse-cdn.com/flex016/user_avatar/community.weweb.io/fynn/32/15124_2.png) [@fynn](https://community.weweb.io/u/fynn)
#### Post date: [September 2, 2025, 8:29am UTC](https://community.weweb.io/t/github-push-overwrites-vercel-json-and-workflows/19844/1 "2025-09-02T08:29:24Z")

</div>

Hey everyone,

I’m working on a project with WeWeb + GitHub + Vercel and ran into an issue I can’t find a good workaround for.

WeWeb’s GitHub publishing seems to completely overwrite the branch root on every publish – including:

- my `vercel.json` file
- my custom GitHub Actions under `.github/workflows`

Even if I try to include the `vercel.json` file via the “files” option in WeWeb, it ends up in the wrong place: `public/vercel.json`.  
This breaks things like SPA rewrites and other Vercel config.

I also can’t use a GitHub Action to move the file back after publishing, because the `.github` folder is already deleted when WeWeb overwrites the branch.

I would really like to keep using the built-in **WeWeb → GitHub push** functionality – I’d prefer not to download the export manually and push it myself.

Is there a way to publish into a **subfolder** of the branch instead of the root? Or any trick to preserve certain folders/files during a publish?

Would love to hear how others handle this!

Thanks 🙏

---

<div class="post-metadata">

### Author: ![Agustin\_Carozo](https://sea2.discourse-cdn.com/flex016/user_avatar/community.weweb.io/agustin_carozo/32/13231_2.png) [@Agustin\_Carozo](https://community.weweb.io/u/Agustin_Carozo)
#### Post date: [September 2, 2025, 1:35pm UTC](https://community.weweb.io/t/github-push-overwrites-vercel-json-and-workflows/19844/2 "2025-09-02T13:35:45Z")

</div>

Hi Fynn 👋

While we wait to see how others have solved this, I’ll ask if someone from the support team has an answer for this.

---

<div class="post-metadata">

### Author: ![Batik\_Okazov](https://sea2.discourse-cdn.com/flex016/user_avatar/community.weweb.io/batik_okazov/32/12688_2.png) [@Batik\_Okazov](https://community.weweb.io/u/Batik_Okazov)
#### Post date: [September 4, 2025, 8:48am UTC](https://community.weweb.io/t/github-push-overwrites-vercel-json-and-workflows/19844/3 "2025-09-04T08:48:54Z")

</div>

Hi Fynn,

In your case presumably I’d try to create new repo (let’s call it “wrapper repo”) and store the vercel.json inside a root folder. Then I’d create in the root folder another folder (let’s call it “weweb\_project”) and set this “weweb\_folder” as a root directory in vercel project settings.

Then we need a trigger (Github action maybe? not familiar either) which will fire each time when Weweb pushes a new version:

1. delete existing files in “weweb\_project” (if any)
2. copy the new Weweb project from “weweb repo” to “wrapper repo/weweb\_project”

I think this should work. Vercel will get static files of the project from “weweb\_project” and the config from the vercel.json placed in the root of the repo. So Weweb won’t be able to overwrite anything.

Let me know if this works.

---

<div class="post-metadata">

### Author: ![Broberto](https://sea2.discourse-cdn.com/flex016/user_avatar/community.weweb.io/broberto/32/5918_2.png) [@Broberto](https://community.weweb.io/u/Broberto)
#### Post date: [September 4, 2025, 12:00pm UTC](https://community.weweb.io/t/github-push-overwrites-vercel-json-and-workflows/19844/4 "2025-09-04T12:00:11Z")

</div>

The probably simplest solution to this seems to be just pull the vercel.json from the `/public` via a Workflow 😃

---

<div class="post-metadata">

### Author: ![fynn](https://sea2.discourse-cdn.com/flex016/user_avatar/community.weweb.io/fynn/32/15124_2.png) [@fynn](https://community.weweb.io/u/fynn)
#### Post date: [September 4, 2025, 12:07pm UTC](https://community.weweb.io/t/github-push-overwrites-vercel-json-and-workflows/19844/5 "2025-09-04T12:07:23Z")

</div>

WeWeb overrides the Worflows in the branch so nothing gets triggered. I’ve also tried triggering workflows from other branches, for example, when pushing to staging. No success.

---

<div class="post-metadata">

### Author: ![ginkelb](https://sea2.discourse-cdn.com/flex016/user_avatar/community.weweb.io/ginkelb/32/5579_2.png) [@ginkelb](https://community.weweb.io/u/ginkelb)
#### Post date: [December 24, 2025, 9:17am UTC](https://community.weweb.io/t/github-push-overwrites-vercel-json-and-workflows/19844/6 "2025-12-24T09:17:28Z")

</div>

We also just figured this out.  
Would really love for weweb to ignore certain files in the repo so we can use our deployment street as we’ve imagined it.
