Snippets Contact form

Bootstrap 5 Contact Form with News Panel

A contact form paired with a latest-news panel, so visitors can read updates while they write to you.

Bootstrap 5 No jQuery Apr 2020 2K views

<section class="wdw-stage">
  <div class="container" style="max-width: 68rem;">
    <div class="wdw-card overflow-hidden">
      <div class="row g-0">
        <div class="col-lg-5 wdw-aurora p-4 p-lg-5">
          <span class="wdw-eyebrow mb-2 text-white opacity-75">Latest news</span>
          <h2 class="fw-bold h3 mb-4">From the studio</h2>
          <ul class="list-unstyled d-grid gap-4 mb-0">
            <li>
              <p class="small mb-1"><span class="wdw-tag">News</span><span class="opacity-75">Oct 24</span></p>
              <h3 class="h6 fw-bold mb-1"><a href="#" class="link-light link-underline-opacity-0 link-underline-opacity-100-hover">We opened a second studio in Lisbon</a></h3>
              <p class="small opacity-75 mb-0">More room for the team, and a new home for our design workshops.</p>
            </li>
            <li>
              <p class="small mb-1"><span class="wdw-tag">Articles</span><span class="opacity-75">Oct 11</span></p>
              <h3 class="h6 fw-bold mb-1"><a href="#" class="link-light link-underline-opacity-0 link-underline-opacity-100-hover">How we cut our design handoff time in half</a></h3>
              <p class="small opacity-75 mb-0">Three small habits that changed how designers and developers work together.</p>
            </li>
            <li>
              <p class="small mb-1"><span class="wdw-tag">News</span><span class="opacity-75">Sep 28</span></p>
              <h3 class="h6 fw-bold mb-1"><a href="#" class="link-light link-underline-opacity-0 link-underline-opacity-100-hover">Our 2026 open-source toolkit is live</a></h3>
              <p class="small opacity-75 mb-0">Components, tokens and templates, free for everyone to use.</p>
            </li>
          </ul>
          <a href="#" class="wdw-readall d-inline-block mt-4 link-light">Read all news →</a>
        </div>
        <div class="col-lg-7 p-4 p-lg-5">
          <span class="wdw-eyebrow mb-2">Contact us</span>
          <h2 class="wdw-heading h3 mb-1">Tell us about your project</h2>
          <p class="wdw-muted mb-4">We usually reply within one working day.</p>
          <form id="newsContactForm" novalidate>
            <div class="row g-3">
              <div class="col-sm-6">
                <div class="form-floating">
                  <input type="text" class="form-control" id="ncFirst" placeholder="First name" autocomplete="given-name" required aria-describedby="ncStatus">
                  <label for="ncFirst">First name</label>
                </div>
              </div>
              <div class="col-sm-6">
                <div class="form-floating">
                  <input type="text" class="form-control" id="ncLast" placeholder="Last name" autocomplete="family-name" required aria-describedby="ncStatus">
                  <label for="ncLast">Last name</label>
                </div>
              </div>
              <div class="col-12">
                <div class="form-floating">
                  <input type="email" class="form-control" id="ncEmail" placeholder="[email protected]" autocomplete="email" required aria-describedby="ncStatus">
                  <label for="ncEmail">Email address</label>
                </div>
              </div>
              <div class="col-12">
                <div class="form-floating">
                  <textarea class="form-control wdw-news-msg" id="ncMsg" placeholder="Message" required aria-describedby="ncStatus"></textarea>
                  <label for="ncMsg">Message</label>
                </div>
              </div>
              <div class="col-12">
                <button type="submit" class="btn btn-primary rounded-pill w-100">Send message</button>
                <p class="small wdw-muted text-center mt-3 mb-0" id="ncStatus" role="status" aria-live="polite"></p>
              </div>
            </div>
          </form>
        </div>
      </div>
    </div>
  </div>
</section>

Built on Bootstrap 5.3.8 with plain JavaScript — no jQuery. Supports light and dark mode via data-bs-theme.

Free to use in personal and commercial projects under the MIT license.