# DFX CLI, just a question, why is "dfx build" not "dfx canister build"

**URL:** <https://forum.dfinity.org/t/dfx-cli-just-a-question-why-is-dfx-build-not-dfx-canister-build/2001>\
**Category:** Command Line Tools\
**Created:** [February 18, 2021, 5:40am UTC](https://forum.dfinity.org/t/dfx-cli-just-a-question-why-is-dfx-build-not-dfx-canister-build/2001 "2021-02-18T05:40:28Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![levifeldman](https://sea1.discourse-cdn.com/flex023/user_avatar/forum.dfinity.org/levifeldman/32/1034_2.png) [@levifeldman](https://forum.dfinity.org/u/levifeldman)\
**Post date:** [February 18, 2021, 5:40am UTC](https://forum.dfinity.org/t/dfx-cli-just-a-question-why-is-dfx-build-not-dfx-canister-build/2001/1 "2021-02-18T05:40:28Z")

</div>

i think about it every time, shouldnt the build command be under dfx canister? just like dfx canister install and dfx canister create? wondering why for the placement-choice?

---

<div class="post-metadata">

**Author:** ![jzxchiang](https://sea1.discourse-cdn.com/flex023/user_avatar/forum.dfinity.org/jzxchiang/32/2592_2.png) [@jzxchiang](https://forum.dfinity.org/u/jzxchiang)\
**Post date:** [April 16, 2022, 10:55pm UTC](https://forum.dfinity.org/t/dfx-cli-just-a-question-why-is-dfx-build-not-dfx-canister-build/2001/2 "2022-04-16T22:55:45Z")

</div>

Because it builds it for all the canisters in your `dfx.json`, not necessarily just for a single canister.

---

<div class="post-metadata">

**Author:** ![icme](https://sea1.discourse-cdn.com/flex023/user_avatar/forum.dfinity.org/icme/32/4327_2.png) [@icme](https://forum.dfinity.org/u/icme)\
**Post date:** [April 17, 2022, 5:32am UTC](https://forum.dfinity.org/t/dfx-cli-just-a-question-why-is-dfx-build-not-dfx-canister-build/2001/3 "2022-04-17T05:32:24Z")

</div>

Erm, that’s not necessarily true. @levifeldman brings up a good point about the inconsistency in the cli api.

```auto
% dfx canister status  
error: The following required arguments were not provided:
    --all

USAGE:
    dfx canister status --all

For more information try --help

```

---

<div class="post-metadata">

**Author:** ![jzxchiang](https://sea1.discourse-cdn.com/flex023/user_avatar/forum.dfinity.org/jzxchiang/32/2592_2.png) [@jzxchiang](https://forum.dfinity.org/u/jzxchiang)\
**Post date:** [April 17, 2022, 5:54am UTC](https://forum.dfinity.org/t/dfx-cli-just-a-question-why-is-dfx-build-not-dfx-canister-build/2001/4 "2022-04-17T05:54:49Z")

</div>

Hm interesting, you’re right. I guess probably because building a canister is so common that they wanted to make the command short?

---

<div class="post-metadata">

**Author:** ![AdamS](https://sea1.discourse-cdn.com/flex023/user_avatar/forum.dfinity.org/adams/32/5248_2.png) [@AdamS](https://forum.dfinity.org/u/AdamS)\
**Post date:** [April 18, 2022, 10:58pm UTC](https://forum.dfinity.org/t/dfx-cli-just-a-question-why-is-dfx-build-not-dfx-canister-build/2001/5 "2022-04-18T22:58:10Z")

</div>

Because dfx-build does not involve any canisters. It builds code into a wasm module.

---

<div class="post-metadata">

**Author:** ![jzxchiang](https://sea1.discourse-cdn.com/flex023/user_avatar/forum.dfinity.org/jzxchiang/32/2592_2.png) [@jzxchiang](https://forum.dfinity.org/u/jzxchiang)\
**Post date:** [April 19, 2022, 1:43am UTC](https://forum.dfinity.org/t/dfx-cli-just-a-question-why-is-dfx-build-not-dfx-canister-build/2001/6 "2022-04-19T01:43:09Z")

</div>

But `dfx deploy` does though… 😀
