Make sure your web application tier follows
The Twelve-Factor App[
^] practices which will allow you to horizontally scale your web application. This is quite easy to do once you understand the basic principles.
The hard part is scaling the Database tier. Use as much caching as you can using Redis or Memcached to reduce the load on your db as much as possible. Still how much you will be able scale will depend on your business use cases. At some point you will need to look at:
Shard (database architecture) - Wikipedia[
^].