Bootstrap snippet and html example. bs4 beta view email message

Bootstrap 4.0.0-beta snippet "bs4 beta view email message" with HTML, CSS, and JS. Copy, paste, and customize this responsive UI component for your project.
Tags: email,message,inbox

HTML code

Clean, semantic HTML that powers this Bootstrap 4.0.0-beta snippet. Copy and paste it into your page (with Bootstrap loaded) to reproduce the exact layout shown in the preview.

<link href="https://maxcdn.bootstrapcdn.com/font-awesome/4.3.0/css/font-awesome.min.css" rel="stylesheet">
<div class="container">
<div class="email-app mb-4">
    <nav>
      <a href="#" class="btn btn-danger btn-block">New Email</a>
      <ul class="nav">
        <li class="nav-item">
          <a class="nav-link" href="#"><i class="fa fa-inbox"></i> Inbox <span class="badge badge-danger">4</span></a>
        </li>
        <li class="nav-item">
          <a class="nav-link" href="#"><i class="fa fa-star"></i> Stared</a>
        </li>
        <li class="nav-item">
          <a class="nav-link" href="#"><i class="fa fa-rocket"></i> Sent</a>
        </li>
        <li class="nav-item">
          <a class="nav-link" href="#"><i class="fa fa-trash-o"></i> Trash</a>
        </li>
        <li class="nav-item">
          <a class="nav-link" href="#"><i class="fa fa-bookmark"></i> Important<span class="badge badge-info">5</span></a>
        </li>
        <li class="nav-item">
          <a class="nav-link" href="#"><i class="fa fa-inbox"></i> Inbox <span class="badge badge-danger">4</span></a>
        </li>
      </ul>
    </nav>
    <main class="message">
      <div class="toolbar">
        <div class="btn-group">
          <button type="button" class="btn btn-light">
            <span class="fa fa-star"></span>
          </button>
          <button type="button" class="btn btn-light">
            <span class="fa fa-star-o"></span>
          </button>
          <button type="button" class="btn btn-light">
            <span class="fa fa-bookmark-o"></span>
          </button>
        </div>
        <div class="btn-group">
          <button type="button" class="btn btn-light">
            <span class="fa fa-mail-reply"></span>
          </button>
          <button type="button" class="btn btn-light">
            <span class="fa fa-mail-reply-all"></span>
          </button>
          <button type="button" class="btn btn-light">
            <span class="fa fa-mail-forward"></span>
          </button>
        </div>
        <button type="button" class="btn btn-light">
          <span class="fa fa-trash-o"></span>
        </button>
        <div class="btn-group">
          <button type="button" class="btn btn-light dropdown-toggle" data-toggle="dropdown">
            <span class="fa fa-tags"></span>
            <span class="caret"></span>
          </button>
          <div class="dropdown-menu">
            <a class="dropdown-item" href="#">add label <span class="badge badge-danger"> Home</span></a>
            <a class="dropdown-item" href="#">add label <span class="badge badge-info"> Job</span></a>
            <a class="dropdown-item" href="#">add label <span class="badge badge-success"> Clients</span></a>
            <a class="dropdown-item" href="#">add label <span class="badge badge-warning"> News</span></a>
          </div>
        </div>
      </div>
      <div class="details">
        <div class="title">Neque porro quisquam est qui dolorem ipsum quia dolor sit amet, consectetur, adipisci velit.</div>
        <div class="header">
          <img class="avatar" src="https://bootdey.com/img/Content/avatar/avatar1.png">
          <div class="from">
            <span>Lukasz Holeczek</span>
            [email protected]
          </div>
          <div class="date">Today, <b>3:47 PM</b></div>
        </div>
        <div class="content">
          <p>
            Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor
            in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum.
          </p>
          <blockquote>
            Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor
            in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum.
          </blockquote>
        </div>
        <div class="attachments">
          <div class="attachment">
            <span class="badge badge-danger">zip</span> <b>bootstrap.zip</b> <i>(2,5MB)</i>
            <span class="menu">
              <a href="#" class="fa fa-search"></a>
              <a href="#" class="fa fa-share"></a>
              <a href="#" class="fa fa-cloud-download"></a>
            </span>
          </div>
          <div class="attachment">
            <span class="badge badge-info">txt</span> <b>readme.txt</b> <i>(7KB)</i>
            <span class="menu">
              <a href="#" class="fa fa-search"></a>
              <a href="#" class="fa fa-share"></a>
              <a href="#" class="fa fa-cloud-download"></a>
            </span>
          </div>
          <div class="attachment">
            <span class="badge badge-success">xls</span> <b>spreadsheet.xls</b> <i>(984KB)</i>
            <span class="menu">
              <a href="#" class="fa fa-search"></a>
              <a href="#" class="fa fa-share"></a>
              <a href="#" class="fa fa-cloud-download"></a>
            </span>
          </div>
        </div>
        <form method="post" action="">
          <div class="form-group">
            <textarea class="form-control" id="message" name="body" rows="12" placeholder="Click here to reply"></textarea>
          </div>
          <div class="form-group">
            <button tabindex="3" type="submit" class="btn btn-success">Send message</button>
          </div>
        </form>
      </div>
    </main>
  </div>
  </div>

CSS code

Scoped CSS that styles the component. Paste it after Bootstrap 4.0.0-beta to keep the design, spacing, and responsiveness consistent.

body{margin-top:20px;}
.email-app {
    display: flex;
    flex-direction: row;
    background: #fff;
    border: 1px solid #e1e6ef;
}

.email-app nav {
    flex: 0 0 200px;
    padding: 1rem;
    border-right: 1px solid #e1e6ef;
}

.email-app nav .btn-block {
    margin-bottom: 15px;
}

.email-app nav .nav {
    flex-direction: column;
}

.email-app nav .nav .nav-item {
    position: relative;
}

.email-app nav .nav .nav-item .nav-link,
.email-app nav .nav .nav-item .navbar .dropdown-toggle,
.navbar .email-app nav .nav .nav-item .dropdown-toggle {
    color: #151b1e;
    border-bottom: 1px solid #e1e6ef;
}

.email-app nav .nav .nav-item .nav-link i,
.email-app nav .nav .nav-item .navbar .dropdown-toggle i,
.navbar .email-app nav .nav .nav-item .dropdown-toggle i {
    width: 20px;
    margin: 0 10px 0 0;
    font-size: 14px;
    text-align: center;
}

.email-app nav .nav .nav-item .nav-link .badge,
.email-app nav .nav .nav-item .navbar .dropdown-toggle .badge,
.navbar .email-app nav .nav .nav-item .dropdown-toggle .badge {
    float: right;
    margin-top: 4px;
    margin-left: 10px;
}

.email-app main {
    min-width: 0;
    flex: 1;
    padding: 1rem;
}

.email-app .inbox .toolbar {
    padding-bottom: 1rem;
    border-bottom: 1px solid #e1e6ef;
}

.email-app .inbox .messages {
    padding: 0;
    list-style: none;
}

.email-app .inbox .message {
    position: relative;
    padding: 1rem 1rem 1rem 2rem;
    cursor: pointer;
    border-bottom: 1px solid #e1e6ef;
}

.email-app .inbox .message:hover {
    background: #f9f9fa;
}

.email-app .inbox .message .actions {
    position: absolute;
    left: 0;
    display: flex;
    flex-direction: column;
}

.email-app .inbox .message .actions .action {
    width: 2rem;
    margin-bottom: 0.5rem;
    color: #c0cadd;
    text-align: center;
}

.email-app .inbox .message a {
    color: #000;
}

.email-app .inbox .message a:hover {
    text-decoration: none;
}

.email-app .inbox .message.unread .header,
.email-app .inbox .message.unread .title {
    font-weight: bold;
}

.email-app .inbox .message .header {
    display: flex;
    flex-direction: row;
    margin-bottom: 0.5rem;
}

.email-app .inbox .message .header .date {
    margin-left: auto;
}

.email-app .inbox .message .title {
    margin-bottom: 0.5rem;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.email-app .inbox .message .description {
    font-size: 12px;
}

.email-app .message .toolbar {
    padding-bottom: 1rem;
    border-bottom: 1px solid #e1e6ef;
}

.email-app .message .details .title {
    padding: 1rem 0;
    font-weight: bold;
}

.email-app .message .details .header {
    display: flex;
    padding: 1rem 0;
    margin: 1rem 0;
    border-top: 1px solid #e1e6ef;
    border-bottom: 1px solid #e1e6ef;
}

.email-app .message .details .header .avatar {
    width: 40px;
    height: 40px;
    margin-right: 1rem;
}

.email-app .message .details .header .from {
    font-size: 12px;
    color: #9faecb;
    align-self: center;
}

.email-app .message .details .header .from span {
    display: block;
    font-weight: bold;
}

.email-app .message .details .header .date {
    margin-left: auto;
}

.email-app .message .details .attachments {
    padding: 1rem 0;
    margin-bottom: 1rem;
    border-top: 3px solid #f9f9fa;
    border-bottom: 3px solid #f9f9fa;
}

.email-app .message .details .attachments .attachment {
    display: flex;
    margin: 0.5rem 0;
    font-size: 12px;
    align-self: center;
}

.email-app .message .details .attachments .attachment .badge {
    margin: 0 0.5rem;
    line-height: inherit;
}

.email-app .message .details .attachments .attachment .menu {
    margin-left: auto;
}

.email-app .message .details .attachments .attachment .menu a {
    padding: 0 0.5rem;
    font-size: 14px;
    color: #e1e6ef;
}

@media (max-width: 767px) {
    .email-app {
        flex-direction: column;
    }
    .email-app nav {
        flex: 0 0 100%;
    }
}

@media (max-width: 575px) {
    .email-app .message .header {
        flex-flow: row wrap;
    }
    .email-app .message .header .date {
        flex: 0 0 100%;
    }
}

Similar snippets

Bootstrap example and template. bs4 Message Chat Box

bs4 Message Chat Box

Bootstrap example and template. billing email template

billing email template

Bootstrap example and template. View mail and compose

View mail and compose

Bootstrap example and template. bs4 email app

bs4 email app

Bootstrap example and template. list projects

list projects

Bootstrap example and template. top item list

top item list

Bootstrap example and template. microsoft metro tiles bootstrap

microsoft metro tiles bootstrap

Bootstrap example and template. real estate view property

real estate view property

FAQ

How do I use this snippet?

Include Bootstrap 4.0.0-beta, paste the HTML, add the CSS block, and include the JS (if any) to mirror the live preview.

Can I use it in commercial projects?

Yes. It’s free for personal and commercial work; check the snippets license for details.

Is it responsive?

Yes. It inherits the responsive grid and components from Bootstrap 4.0.0-beta.

Bootstrap example and template. bs4 beta view email message

About this bootstrap example/template

Optimized for copy‑paste: clean HTML, scoped CSS, and minimal JS so you can ship production‑ready UI faster and keep designs consistent.

Mobile‑first and responsive by default. Tested across modern browsers to reduce polish time on your project.

Already trusted in 11.4K+ views. Reuse this snippet to speed up landing pages, dashboards, or onboarding flows.

Bootstrap 4.0.0-beta

<link rel='stylesheet' href='https://netdna.bootstrapcdn.com/bootstrap/4.0.0-beta/css/bootstrap.min.css'>

<script src='https://netdna.bootstrapcdn.com/bootstrap/4.0.0-beta/js/bootstrap.min.js'></script>

This code example is based on bootstrap 4.0.0-beta and the grid system of this framework

Responsive

Based on bootstrap framework makes all the layouts perfectly responsive for all devices

Crossbrowser compatibility

Tested on all major browsers, it works smoothly on all of them

semantic html 5

Built on html / css3 the code quality is really amazing

Simple Integration

This code example can be simply integrated on existing sites and new ones too, all you need to do is copy the code and start working