The number of pieces in a software puzzle

One of the fundamental architectural decision when designing software is to decide how the software is delivered. Is it delivered in a single, complete, self-sufficient package or will it be delivered in multiple small packages that are independent but interacting with each other.

This is the decision between monolithic and microservice architecture. Both of the options have good and bad sides, and whatever fits some software may not be reasonable for another. The decision, which one is better for a particular software, may be non-trivial.

If it is too hard to decide or being pragmatic outweighs being dogmatic you may end up with a modular monolith, or modulith, architecture that is in between the two extremes mentioned.

Whatever you decide can be adapted later on. However, like with most architectural decisions, adjusting the existing implementation to match changes in the architecture may be too expensive task to do.