DEV Community

Cover image for Frontend vs. Backend
Hasan Elsherbiny
Hasan Elsherbiny

Posted on

Frontend vs. Backend

if you are new to the world of the web development ,you will have to know some important terms, two of these terms are frontend and backend.
so what are these two terms?
most of web applications are based on the model called Client Server model.

Client Server Model

client server model

in this model your website (the application you have created) is hosted on a Computer (called server) this application is waiting for incoming requests to start to handle it, in this scenario the waiting application is called Backend (consider it as the backstage).

and the caller is called frontend which initiate the request or ask for a specific resource (exists on the server).

sounds good but why?

why don't we place everything on the frontend and this is gonna be faster and high latency.
the problem here is:

  1. difference between resources at the each caller client
    What if the caller client wants to execute a process requires high processing power and high memory requirements?
    in this case our theory will fall.

  2. if we placed everything at the frontend if user's device is lost or broken the stored data is lost too.

  3. different client's platforms
    our application can be used be different consumers with different platforms and it can cause a change of expected behavior of our code.

ok let's do everything on the backend.
in this case will have much headache on the server requiring us to increase resources allocated to the server.

for these problems the client server model is handy and the optimal solution is to use mixture between the backend and frontend.

the backend should has the pardon of executing processes requiring high resources as mentioned before and also must be responsible for accessing the database and carrying out transactions based on each user's roles.

the frontend should expose easy to use and pretty UI to the user and any interaction between the user and the UI should be executed at frontend to reduce ovehead of the server.

What technologies you need for the backend?

a lot of Programming languages and frameworks are there for developing backend, most common are:

  1. PHP
  2. Asp.net (C#-Vb.net)
  3. Ruby on rails (ruby)
  4. Node.Js (javascript)
  5. Spring (java) ## What technologies you need for the frontend? Mainly you need HTML , CSS and JavaScript for frontend development but there are also a lot of frameworks facilitating the usage of CSS and JavaScript.

Top comments (2)

Collapse
 
armagondo profile image
armagondo

really loved this article.

Collapse
 
hasanelsherbiny profile image
Hasan Elsherbiny

thanks, have a look on my other articles