Avery Phillips

@alorphillips

The Importance of Responsive Web Design for Optimal User Experience

The Importance of Responsive Web Design for Optimal User Experience

Recently, responsive design trends have been changing the face of the internet. With each year of innovation, it is becoming a far more accessible, visually diverse, and vibrant source of entertainment and information. More websites are accessible on a wider range of devices than ever before.

Is your website a part of this revolution in design — or are you risking leaving your business in the dust by sticking to design principles that are over a decade old? Let’s take a look at the benefits of responsive web design (RWD), as well as what you can do to optimize your site’s user experience:

The Benefits of Responsive Web Design

There are many reasons for businesses and web developers to use RWD principles. Content creators have an obligation to meet consumers where they are, and an increasing number of users are regularly accessing the internet on a wide range mobile devices, often with more frequency than on traditional desktop computers. RWD ensures that your content will display correctly for all users, providing a stronger user experience and ultimately more conversions.

Note that RWD is distinct from adaptive web design. While the latter focuses on the creation of several distinct layouts to suit multiple screen sizes, truly responsive design is “fluid”; it uses CSS media to change styles and resize to match the needs of any device. As a result, it is far more flexible, and future-proof — considering the introduction of new devices, such as wearables and IoT tech. It can even automatically adjust content to suit screens when users switch from landscape to portrait mode, and vice versa. While it’s not possible to create a design that will accommodate every screen that exists (or will exist in the future), smart RWD improves accessibility so that the widest possible range of users can easily access your content.

While switching to RWD may come with some initial work, there are other benefits that definitely make these efforts with it. Instead of creating various layouts for different devices, one responsive design will suit any screen. While the HTML and CSS code for a responsive design is more complex, it is the same code and the same URL regardless of device. This makes it much easier for developers and content managers to administer.

Your First Steps Towards a Better User Experience

So, how can get you get started on offering an optimal user experience? If you lack website design skills, you may be tempted to use a DIY website builder, or a template, to complete your work; they are inexpensive and accessible enough for nearly any small business to use. However, resist that urge — such templates often fail to follow digital marketing and search engine optimization best practices.

Your approach to RWD will vary, depending on the needs of your audience and your specific niche/industry. What are the demographics of your target audience? What does the consumer journey look like? The design of your site should facilitate a smooth experience. For instance, if you operate a healthcare website, keep in mind that most users (77 percent) use a search engine in regards to their health-related questions prior to booking an appointment. With that in mind, web designers should have content specialists create resources that will attract users by answering their questions and establish your site as an authoritative source. These sites should also seek to make booking an appointment as easy as possible.

Eager to get started with the nitty gritty of RWD? Here are some basics to keep in mind:

Controlling the Viewport

With the introduction of HTML5, web designers gained the ability to take control of the viewport, or the visible area of a page. You need to include the viewport <meta> tag in each page on your site, which looks like this:

<head>

<meta name=”viewport” content=”width=device-width, initial-scale=1">

</head>

The “width=device-width” adjusts the content attribute to suit the width of the device being used. The “initial-scale=1” sets the initial zoom level when the page is loaded, with 1 being the standard zoom level. Because users are not able to scroll horizontally, you may need to adjust the scale to fit all of your content on the screen — however, it is much wiser to adjust your content to fit the width of the viewport.

In general, you should avoid using set CSS widths for page elements; if you do so, you risk making content too large for smaller screens. Use relative width values, such as: “width: 100%” instead of set values. The same general rule applies to setting the widths of columns in your grid-view.

Designing Your Layout in Grid-View

Next, you’ll want to use a grid-view to design the layout for your site. A “grid-view” is divided into columns, with many responsive sites having around 12 columns. Using relative width values, this means each column should consist of 8.33 percent of the screen, for a total of 100 percent. Here is an example of a 12-column design created by W3Schools.com:

.col-1 {width: 8.33%;}

.col-2 {width: 16.66%;}

.col-3 {width: 25%;}

.col-4 {width: 33.33%;}

.col-5 {width: 41.66%;}

.col-6 {width: 50%;}

.col-7 {width: 58.33%;}

.col-8 {width: 66.66%;}

.col-9 {width: 75%;}

.col-10 {width: 83.33%;}

.col-11 {width: 91.66%;}

.col-12 {width: 100%;}

In the example above, the designer makes each column float to the left, with a padding of 15 pixels and a border of 1 pixel:

[class*=”col-”] {

float: left;

padding: 15px;

border: 1px solid red;

}

Because each column is floating to the left, other elements will be placed on the page as though the columns are not present. To fix this, you’ll need to clear the flow for each element. This is fairly simple:

.row::after {

content: “ “;

clear: both;

display: table;

}

Setting Breakpoints

Responsive pages adjust when specific criteria are met. When designing pages to look good on a wide variety of devices, it is essential to create breakpoints — these are the specified widths at which a page resizes. By setting media queries (the “@media”) at common screen sizes, you ensure that your site responsive to a wide array of devices.

Here is an example of how this would look in the 12-column grid-view design listed above by W3Schools:

/* For mobile phones: */

[class*=”col-”] {

width: 100%;

}

@media only screen and (min-width: 600px) {

/* For tablets: */

.col-s-1 {width: 8.33%;}

.col-s-2 {width: 16.66%;}

.col-s-3 {width: 25%;}

.col-s-4 {width: 33.33%;}

.col-s-5 {width: 41.66%;}

.col-s-6 {width: 50%;}

.col-s-7 {width: 58.33%;}

.col-s-8 {width: 66.66%;}

.col-s-9 {width: 75%;}

.col-s-10 {width: 83.33%;}

.col-s-11 {width: 91.66%;}

.col-s-12 {width: 100%;}

}

@media only screen and (min-width: 768px) {

/* For desktop: */

.col-1 {width: 8.33%;}

.col-2 {width: 16.66%;}

.col-3 {width: 25%;}

.col-4 {width: 33.33%;}

.col-5 {width: 41.66%;}

.col-6 {width: 50%;}

.col-7 {width: 58.33%;}

.col-8 {width: 66.66%;}

.col-9 {width: 75%;}

.col-10 {width: 83.33%;}

.col-11 {width: 91.66%;}

.col-12 {width: 100%;}

For more information on the specifics of responsive design, check out W3Schools and Google’s Tools for Web Developers.

Looking to the Future of Responsive Design

As the years pass, consumers will grow to expect RWD of nearly every site they frequent. Web designers will need to find new ways to innovate, draw interest, and improve site accessibility. It is important to stay abreast of current design trends and continually update your site to improve the user experience.

What is the future of responsive web design? As we move forward, constantly ask: “How will consumers be interacting with my site?” Wearable technology is rapidly growing in popularity. In the not-so-distant future, users with a great variety of devices, with various screen sizes and limitations, will attempt to visit your site. Audio input will continue to play a major role in how people access information on your site. New modes of input, such as virtual and augmented reality, will fundamentally change how people navigate the web. It’s your job to make sure they don’t leave disappointed.

More by Avery Phillips

Topics of interest

More Related Stories