Tips For Building a Website With ChatGPT

The whole world has been talking about ChatGPT. You can’t visit YouTube or social media without seeing someone talking about what they asked the AI chatbot today. So here at InMotion Hosting, we’ve been putting this handy little bot through its paces, and the results have been interesting.

We asked, “Can you use ChatGPT to help build a website?” And we got some answers.

Below you’ll find a few tips to keep in mind if you want to use ChatGPT to build your new website. Remember, this project is brand new, and improvements and updates are being rolled out consistently. Also, while the tool is free to try today, it may switch to a paid model some time in the future.

If you don’t have an account to try out the AI, you can go the OpenAI website to get started. From there, you will be prompted to start chatting with the bot.

Limited Knowledge of Present Time

As the main chat page says, the AI has a “Limited knowledge of the world and events after 2021.” So it will not be able to tell you the weather forecast, or make a prediction about any present or future event.

For example, the question, “What’s in the new version of WordPress?” will not provide any usable results.

Just Ask, But Don’t Expect Perfection

Some of the output you will get from ChatGPT is surprisingly good, but much of it will require some tweaking. Remember, it’s a piece of software, not magic. The AI is still new, and will improve over the years. For now, take each output with a grain of salt and don’t expect miracles.

If you use the chatbot to generate code for your site, you have no guarantee that the code will function as intended. Rigorous testing is still a requirement.

Try To Keep Your Code Modular

The ChatGPT output will stop itself if it grows too large. So don’t ask the AI for an entire app.

For example, if you’re building a WordPress theme, you could ask for a code sample for a widget area, and it will provide this quite easily. You could also ask for the code to generate a comment section.

Also, the code output will be generic. Function definition will be given arbitrary names based on your input. It’s best to be as specific as possible and customize your code samples to meet your needs.

A Real-World Example

I asked the AI to help me write a WordPress plugin that could identify aging posts that might be in need of an update. This would help a blogger check if an older post should be updated or modified to reflect new information.

The plugin would go through posts in the database, sort them by the last modified date, and also count how many days it’s been. Then it would aggregate all this information into a table displayed in a metabox in the admin area.

The output worked, but not as expected. When I wanted to add some custom CSS, the AI couldn’t figure out exactly where I wanted it. This could be a limitation of the program, or my failure to describe exactly what I wanted.

Nevertheless, I tweaked the code output myself to get the desired effect.

Voila, I now have a metabox in the Dashboard displaying table of old posts I should go back and update:

Custom WordPress plugin made with AI assistance.

Think Of Your Output As Advice

At the moment, ChatGPT is a free research tool. It’s no replacement for a live developer, unless you are prepared to do a lot of work yourself.

For now, it’s best to think of the output you get as advice to see how something can be done.

For instance, you can ask for a basic code snippet and get an “example” of how your desired result can be achieved.

But if you want something more specific, customized, and unique, you may need to continue to iterate on your new code independently or hire a developer to take the project to the finish line.

Expect Delays

ChatGPT is a highly popular tool, available to the public for free at the moment. So it tends to go down quite frequently throughout the day due to high volume. So while you may get accustomed to this handy code dispensary, you might still need to do the bulk of your work independently.

Leave a Reply

Your email address will not be published. Required fields are marked *