DEV Community

Cover image for NHOST: AN INTRODUCTION TO BACK-END AS A SERVICE.
WISDOMUDO
WISDOMUDO

Posted on • Updated on

NHOST: AN INTRODUCTION TO BACK-END AS A SERVICE.

Are you having trouble as a front-end or back-end developer creating a single app from scratch? If so, worry no longer. Many products and services have entered the market over the forecast period, which lessens the power of this.

In this article, you will learn about Nhost as an open-source firebase alternative with GraphQL that deploys both web and mobile apps seamlessly, and we will consider the following subject.

What is Nhost
Installation
Nhost services
How to create a database in Nhost
Why Nhost
Nhost vs Netlify
Conclusion

What is Nhost?

Image description

Nhost is a serverless back-end application that allows you to build a web and mobile application without having to worry about infrastructure management. It includes the GraphQL backend and full development; a cloud-based system that allows you to create mobile, web, and digital products.

Nhost is seamlessly integrated, and incorporated with innovative front-end technologies such as ReactJS, Next.js, Vue.js, flutter, and many others.

How to Get Started with Nhost

Nhost is a user-friendly software application that allows anyone to navigate through freely; you can sign up either with your GitHub credentials or your email address.

Image description

Now look at the image above; you will see an arrow that bears no.1 and will ask you to sign up through your GitHub account. While the second arrow with no.2 will ask you to sign up with your email address; click on the first arrow (one), which will take you to the next page:

Image description

Once done with authorizing the Nhost and the signing up process, the next step is to visit: The nhost site to access the workspace; that will take you to the next page. See below!

Image description

Congratulations, you are set to kickstart your first project; click on the button and start building.

Now, let's look at how to set up our first project on Nhost:

How to set up a new project on Nhost

To do that, you must first provide the following details:

  1. Project name (e.g: countApp)
  2. Workspace, where the project will be created (e.g: WisdomUdo)
  3. Password. (e.g: “123$%Uryis”)
  4. Region (e.g “ London”).
  5. Plan (e.g: “Free or Pro”)

Image description

Once, provided the above details, click “Create Project”.

What are the Nhost Services?

Here, we will list out the basics services provided by Nhost; see

How to create a Database in Nhost

Here we will look at how to create a database with the Postgres database in Nhost. Postgres is an open-source database that supports relational (SQL) and non-relational (JSON) querying.

I will illustrate how to create a “CarHire Database” and show you step-by-step guides on how to get it done.

Let's get our hands dirty;

  • Login to the nhost site either with your Github credential or email address.
  • Click on create new project

Image description

  • Set up your “Project Name” ( E.g ‘carHire’ )

Image description

Thereafter, click on “Create Project” and wait awhile for the system to finish the configuration process. Having done that, it’ll take you to the next page, as shown below!

Image description

Image description

  • Click on the “Database” to create a Table.

  • Once, that’s done you’ve to give your table a “Name

Image description

  • Add columns
  • Specify a primary key (that’ll be your id columns)
  • Add foreign key ( is optional)
  • Finally, click on the create button.

    See the image below!

Image description

From the image above, you’ll see number four (4) once you click on it, it’ll create a new table. See the image below.

Image description

Congratulations, you've successfully added a “New Table” called “gallery”.

Why Nhost

According to Johan Eliasson, the founder of Nhost in one of his interviews; he said " _I realized building a new backend for every app was not time well spent. when looking for the perfect backend, I found out it didn't exist. Now, this is the beauty of being an engineer. If you want something that does not exist, you can build it yourself, which I did.

In the early days of Nhost, I received a lot of traction from other developers who also wanted to have a ready-to-use backend. The feedback kept me motivated to build a fantastic experience for other developers who, just like me, love to develop._" read more..

Nhost vs Netlify

Here, we’ll look at the comparison of both technologies.

SN Nhost Netlify
1 Firebase alternative (open-source)with GraphQl. Build, deploy and host your static site or app with a drag-and-drop interface and automatic deploys from GitHub or Bitbucket.
2 Back-end as a service (Baas). Platform-as-a-service (Paas).
3 All permission is handled by Hasura. Permission is handled with two systems ( file storage & GraphQL).
4 Unlimited free access to all features. Limited access to most features.
5 It Comes with developer tools. Cloud computing.

Conclusion

Nhost is a back-end web-based development platform that allows developers to build web and mobile apps without bothering about the infrastructure; because it comes with GraphQL technology.

However, in this article, we have been able to share with you the meaning of Nhost, and also present a table of comparison between Nhost and Netlify: then the services that come with it, and further show you how to create your first database with Nhost.

Finally, it will be nice to seize this opportunity to learn more about Nhost and take advantage of it.

Top comments (0)