Skip to content

Product Inventory Table with Thumbnails

Bootstrap 5 inventory table with product thumbnails, SKUs, prices, color-coded stock meters, status badges, search, filters and sorting.

Also known as: inventory management table, stock table with thumbnails, product stock table, admin product list, warehouse inventory table

Product Inventory Table with Thumbnails live demo

Open in new tab

Bootstrap 5 code (HTML, CSS, JS)

A Bootstrap 5 product inventory table with photo thumbnails, SKUs, prices, color-coded stock meters and status badges, plus search, a category filter, a low-stock switch and sortable columns. It suits store admin panels, warehouse dashboards and back-office product lists.

How it works

The root section.inv-wrap contains .inv-card with a header (.inv-head) holding the title, the live .inv-value total and the .inv-tools controls. On medium screens and up the tools sit next to the title; on phones they stack. The table.inv-table lives in a .table-responsive wrapper, so it scrolls horizontally on narrow screens.

Every product row stores its data in attributes: data-inv-name, data-inv-sku, data-inv-category, data-inv-price and data-inv-stock. The first cell shows a square .inv-thumb image with object-fit: cover next to .inv-name and the monospace .inv-sku. The stock cell uses a native meter element with low="1", high="11" and optimum="100", so the browser picks the bar color by itself: green from 11 units, amber from 1 to 10 and red at 0. The CSS styles the WebKit and Firefox meter pseudo-elements with --inv-ok, --inv-low and --inv-out. Status uses .inv-badge--ok, .inv-badge--low and .inv-badge--out.

The script runs on DOMContentLoaded for every .inv-wrap. applyFilters() listens to input on .inv-q, change on .inv-cat and change on .inv-low-only. It hides rows that do not match, shows the .inv-empty row when nothing is left, recalculates the stock value (price times stock of visible rows, formatted with Intl.NumberFormat) and updates .inv-foot. The .inv-sort buttons sort by name, price or stock, toggle between ascending and descending and set aria-sort on the header cell.

The product photos come from Unsplash; replace them with your own product images.

Customization

  • --inv-accent in .inv-wrap: recolors the stock value, the active sort header, focus rings and the switch.
  • --inv-ok, --inv-low and --inv-out in .inv-wrap: change the meter colors for healthy, low and empty stock.
  • --inv-thumb in .inv-wrap: makes the product thumbnails larger or smaller.
  • data-inv-low on .inv-wrap: sets the limit used by the "Low stock only" switch (default 10).
  • low, high and max on each meter: move the color thresholds or the full-bar value, e.g. max="500" for a warehouse.
  • Add option elements to .inv-cat that match the data-inv-category values of your rows.
  • data-inv-sort on an .inv-sort button: names the data-inv-* attribute to sort by; name sorts alphabetically, any other key numerically.

Use cases

  • Ecommerce admin panels: product thumbnails, SKUs and prices appear in one searchable table
  • Warehouse tools: color-coded stock meters and status badges show low and out-of-stock items at a glance
  • Catalog management: filters and sortable columns help staff find products quickly
  • Retail back offices: search narrows a long list of products by name or SKU

Accessibility

The table has a visually hidden caption and scope="col" headers. Sortable headers contain real buttons and expose the current order through aria-sort. The search field and category select have visually hidden labels, and the switch uses role="switch" with a visible label. Each meter is labelled "Stock level" and its number is also shown as text. .inv-foot is a role="status" region that announces how many products are shown. Every thumbnail has descriptive alt text, width and height, and the controls have visible focus styles.

Usage notes

Requires Bootstrap 5 and Bootstrap Icons. Update the status badges together with the stock numbers when you render rows from your own data.

Product Inventory Table with Thumbnails at a glance

Framework
Bootstrap 5
Code
HTML, CSS, JavaScript
JavaScript
Vanilla JavaScript, no jQuery
Dependencies
Bootstrap 5, Bootstrap Icons
Layout
Responsive, works on mobile
Category
Tables
License
Free for personal and commercial use

Questions about this template

Can I use the Product Inventory Table with Thumbnails code for free?

Yes. You can copy or download the code and use it in personal and commercial projects, including client work. No sign-up is needed. Reselling it as part of a component library or template collection is not allowed; see the license.

How do I add it to my website?

Load Bootstrap 5 and Bootstrap Icons from a CDN (the links are under Requirements). Paste the HTML where the component should appear, add the CSS to your stylesheet and load the JavaScript before the closing </body> tag. Download HTML gives you a complete page with everything already linked.

Does it need jQuery or a JavaScript framework?

No. The script is plain vanilla JavaScript, so it works without jQuery, React or Vue. You can still use the markup inside those frameworks.

Does it work on mobile?

Yes. The layout adapts to small screens. Use the Mobile and Tablet buttons above the live demo to check it at phone and tablet width.

Requirements

Add these to your page (already included in the download):

  • <link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/bootstrap@5.3.3/dist/css/bootstrap.min.css">
  • <script src="https://cdn.jsdelivr.net/npm/bootstrap@5.3.3/dist/js/bootstrap.bundle.min.js"></script>
  • <link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/bootstrap-icons@1.11.3/font/bootstrap-icons.min.css">
Product Inventory Table with Thumbnails – free Bootstrap 5 table template
Product Inventory Table with Thumbnails · free Bootstrap 5 table template

More Tables

Table with Search Filter – free Bootstrap 5 table template

Table with Search Filter

Bootstrap 5 team directory table with live search, status filter, highlighted matches, result counter and empty state.

Sortable Data Table – free Tailwind CSS table template

Sortable Data Table

Tailwind CSS data table with clickable column headers that sort text, dates and numbers, with aria-sort, arrow indicators and a responsive scroll wrapper.

Table with Search and Pagination – free Bootstrap 6 table template

Table with Search and Pagination

Bootstrap 6 customer table with debounced live search and match highlighting, sortable columns with aria-sort, a rows-per-page select and smart pagination.

Responsive Table with Actions – free Bootstrap 6 table template

Responsive Table with Actions

Bootstrap 6 invoice table with status badges, per-row action Menus, a delete confirmation Dialog, Toast feedback and stacked cards on narrow screens.

Editable Table with Inline Editing – free Bootstrap 5 table template

Editable Table with Inline Editing

Dark Bootstrap 5 inventory table with click-to-edit cells, validation, live totals, an unsaved changes counter and simulated save and discard.

Product Comparison Table Section for Shopify – free Shopify table template

Product Comparison Table Section for Shopify

Shopify section with a real comparison table for 2 to 4 products: live prices, yes/no icons, row values set in the theme editor, and a sticky first column when it scrolls on phones.