Sharding involves dividing data into smaller partitions to distribute workload and improve query response times.