How to delete large numbers of ocean chunks in Minecraft?

Solution 1:

One method you can use is to delete specific world anvil files. These files contain 512 X 512 block sections (32 X 32 chunks). These files are located in the region folder within the world folder.

You can use this dinnerbone coordinate tool to convert coordinates to the appropriate anvil file name. Then you have to verify there is no builds or other things you don't want to lose within the bounds of that file. Then you can delete the file. I recommend you move the file into another backup folder so you can undo changes if you do happen to delete something you didn't intend to.

It may be a bit tedious if you are wanting to delete a lot. You can mark 4 corners of large oceans and delete all the files that fall in that range.

After this, those files will have to be completely regenerated as you explore them as though you have never been there. They will be generated in whatever version you are playing.

Solution 2:

IronAnvil told you how to delete entire region files, but if you want to delete parts of it, you need NBTExplorer.

You can open your saves folder in that program and go to region, then the region file that you want (again calculated from coordinates using this tool (archive)). Open it and you'll find a list of chunks. You can delete those with the Delete key. Make sure to save it with the "save all modified tags" button.

You could also modify single blocks or entities with that program, but that wouldn't cause the chunk to get regenerated.