System design: Horizontal vs vertical scaling

- 1 min



Imagine we have a REST API service, which provides services to customers who pay. The service surely resides in a server. The server could be in the cloud or a personal server.

What if, after a successful year of campaign customer base almost tripled. Now the server needs scaling as it is not initially made for that kind of load.


There’s two types of scaling

Horizontal Scaling

If you are adding more and more servers to the system, that is called horizontal scaling. For a horizontally scaled system

Vertical Scaling

In case you are increasing resources (like ram, storage) in the same server that is called Vertical scaling. In vertical scaling,


So which one should we use? This depends on the requirement. You need to consider what at stake if scale out or scale up the server.

rss facebook twitter github youtube mail spotify lastfm instagram linkedin google google-plus pinterest medium vimeo stackoverflow reddit quora quora