Skip to content
A pagination for aspnetcore applications
Branch: master
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Type Name Latest commit message Commit time
Failed to load latest commit information.


A pagination for aspnet core applications. Easily create paginations for your tabular/list data display pages. By default the styling is done assuming that you are using bootstrap. But everything can be overridden and customized.

How to use

  1. Install from nuget Install-Package ExicoPaginationCore -Version 1.0.0

  2. In your Startup.cs add the pagination

    public void ConfigureServices(IServiceCollection services)
  3. Now import the namespace in your _ViewImports.cshtml by adding this following line

    @using ExicoPaginationCore

  4. Then in your view file use this extension method to render pagination


    This method takes three parameters i.e.

    @Html.RenderPagination((int)ViewBag.TotalCount, (int)ViewBag.ItemsPerPage, config)
    1. Total result count

    2. Items per page

    3. And lastly IPagingConfig instance

      Note that, IPagingConfig can be injected and directly used (as the example above is using)

      @inject IPagingConfig config

      This config object is an instance of the DefaultPaginationConfig (uses bootstrap 4).

      You can also create and object of DefaultPaginationConfig , customize it and pass it as param.

      @Html.RenderPagination((int)ViewBag.TotalCount,(int)ViewBag.ItemsPerPage, new DefaultPaginationConfig()
      HideNextOnLastPage = true,
      HidePrevOnFirstPage = true

      or you can create an entirely new implementation of IPagingConfig and replace the default service registration.

There is a fully working demo project included , check it out TestApplication.csproj !


You can’t perform that action at this time.