To explore the origin of that it, let's take an example sentence:
Playing practical jokes is acceptable.
In order to ascertain the extent to which it is acceptable to play practical jokes, you first remodel the sentence:
It is acceptable to play practical jokes. (It is a dummy pronoun)
Next, you reverse the subject "it" and the auxiliary verb "is":
it is -> is it:
Is it acceptable to play practical jokes?
Next, you add an adverbial phrase, such as "to what extent":
To what extent is it acceptable to play practical jokes?
Or, simply move the adjective "acceptable" in this adverbial position and add "how":
How acceptable is it to play practical jokes?
It a similar vein, your sentence should have that it:
How proper is it to do something?
I changed "right" to "proper" and ditched "much" to comply with FumbleFinger's comments.