Show Output
<!DOCTYPE html> <html lang="en"> <head> <meta charset="utf-8"> <meta name="viewport" content="width=device-width, initial-scale=1"> <title>Bootstrap Responsive Table</title> <link href="https://cdn.jsdelivr.net/npm/bootstrap@5.0.2/dist/css/bootstrap.min.css" rel="stylesheet"> <script src="https://cdn.jsdelivr.net/npm/bootstrap@5.0.2/dist/js/bootstrap.bundle.min.js"></script> <style> /* Custom style to make this example easy to understand */ table * { white-space: nowrap; } </style> </head> <body> <div class="m-4"> <div class="table-responsive"> <table class="table"> <thead> <tr> <th>#</th> <th>First Name</th> <th>Last Name</th> <th>Email</th> <th>Biography</th> </tr> </thead> <tbody> <tr> <td>1</td> <td>Clark</td> <td>Kent</td> <td>clarkkent@mail.com</td> <td>Lorem ipsum dolor sit amet, consectetur adipiscing elit.</td> </tr> <tr> <td>2</td> <td>John</td> <td>Carter</td> <td>johncarter@mail.com</td> <td>Vestibulum consectetur scelerisque bibendum scelerisque purus.</td> </tr> <tr> <td>3</td> <td>Peter</td> <td>Parker</td> <td>peterparker@mail.com</td> <td>Integer pulvinar leo id risus interdum vel metus dignissim.</td> </tr> </tbody> </table> </div> <p class="mt-4"><strong>Note:</strong> Change the editor layout/orientation to see how responsive table works.</p> </div> </body> </html>