# How will split-testing affect the netlify deploy and publishing by netlify-cli

**URL:** <https://answers.netlify.com/t/how-will-split-testing-affect-the-netlify-deploy-and-publishing-by-netlify-cli/43012>\
**Category:** Support\
**Tags:** netlify-cli, split-testing\
**Created:** [August 24, 2021, 11:07pm UTC](https://answers.netlify.com/t/how-will-split-testing-affect-the-netlify-deploy-and-publishing-by-netlify-cli/43012 "2021-08-24T23:07:59Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![clair-hu-525](https://sea1.discourse-cdn.com/netlify/user_avatar/answers.netlify.com/clair-hu-525/32/28537_2.png) [@clair-hu-525](https://answers.netlify.com/u/clair-hu-525)\
**Post date:** [August 24, 2021, 11:07pm UTC](https://answers.netlify.com/t/how-will-split-testing-affect-the-netlify-deploy-and-publishing-by-netlify-cli/43012/1 "2021-08-24T23:07:59Z")

</div>

Hi,

We’re considering using [split testing](https://docs.netlify.com/site-deploys/split-testing/#run-a-branch-based-test) on Netlify for a specific initiative. Do you think this will cause issues with or be prevented by the build triggered by netlify-cli?

Thank you!

---

<div class="post-metadata">

**Author:** ![hrishikesh](https://sea1.discourse-cdn.com/netlify/user_avatar/answers.netlify.com/hrishikesh/32/74607_2.png) [@hrishikesh](https://answers.netlify.com/u/hrishikesh)\
**Post date:** [August 25, 2021, 7:23am UTC](https://answers.netlify.com/t/how-will-split-testing-affect-the-netlify-deploy-and-publishing-by-netlify-cli/43012/2 "2021-08-25T07:23:07Z")

</div>

Hi @clair-hu-525,

Split testing cannot be used with CLI-only deploys as it relies on branch-deploy feature. So, a Git based deploy is a must for Split Testing.

---

<div class="post-metadata">

**Author:** ![clair-hu-525](https://sea1.discourse-cdn.com/netlify/user_avatar/answers.netlify.com/clair-hu-525/32/28537_2.png) [@clair-hu-525](https://answers.netlify.com/u/clair-hu-525)\
**Post date:** [August 25, 2021, 1:10pm UTC](https://answers.netlify.com/t/how-will-split-testing-affect-the-netlify-deploy-and-publishing-by-netlify-cli/43012/3 "2021-08-25T13:10:42Z")

</div>

yeah, i have both git based deploy and cli deploy on that site. so wondering how will split-testing affect the netlify deploy and publishing by netlify-cli

---

<div class="post-metadata">

**Author:** ![hrishikesh](https://sea1.discourse-cdn.com/netlify/user_avatar/answers.netlify.com/hrishikesh/32/74607_2.png) [@hrishikesh](https://answers.netlify.com/u/hrishikesh)\
**Post date:** [August 25, 2021, 1:27pm UTC](https://answers.netlify.com/t/how-will-split-testing-affect-the-netlify-deploy-and-publishing-by-netlify-cli/43012/4 "2021-08-25T13:27:10Z")

</div>

Split testing is divided by branches. So, anything that’s not split would be available only at the deploy URL. However, if you deploy using CLI with the `--prod` flag, that would publish to the production and thus, would be used in Split Testing. However, CLI doesn’t support branch deploys, so branches would remain unaffected.

---

<div class="post-metadata">

**Author:** ![clair-hu-525](https://sea1.discourse-cdn.com/netlify/user_avatar/answers.netlify.com/clair-hu-525/32/28537_2.png) [@clair-hu-525](https://answers.netlify.com/u/clair-hu-525)\
**Post date:** [August 25, 2021, 1:53pm UTC](https://answers.netlify.com/t/how-will-split-testing-affect-the-netlify-deploy-and-publishing-by-netlify-cli/43012/5 "2021-08-25T13:53:03Z")

</div>

> [@hrishikesh](#):
>
> CLI with the `--prod` flag

sounds good, i am using CLI with the `--prod` flag. it sounds like split testing will take care of publishing no matter using CLI or branch deploy. thank you!
