IP to exact location can't be accurate and are paid too. I'm not able to find any freeware yet for IP to city or IP to state.
But still we can find the Country of a particular IP address to allow filter traffic & output based on location. I'm sharing a SQL Server 2016 Database with c# code to update database on regular interval, (weekly or monthly).
Please note that the updates are downloaded from software77.net, you can download latest csv file directly from there.
C# source code & Database