Sign up ×
Unix & Linux Stack Exchange is a question and answer site for users of Linux, FreeBSD and other Un*x-like operating systems. It's 100% free, no registration required.


i am someone1.
i am someone2.
i am someone3

Documentation says G takes me end of the file, but it only takes me to the beginning of last line. I want to be able to come to last character of the file, 3 in this case, and press a and type a period.

How do I do that?

share|improve this question

3 Answers 3

up vote 15 down vote accepted

If you type A after G you will enter insert mode at the end of the last line.

If you just want to go to the last character, then G-End will suffice

share|improve this answer
A then G is fine for me. But if I don't want to edit, is G-End the only option? Is there a single key to do this instead of two? – Nanda Feb 3 '12 at 17:11
Not that I am aware of, but that is no guarantee. You can always create your own map if you like. – Bernhard Feb 3 '12 at 17:17
Thanks Bernhard for the help! – Nanda Feb 3 '12 at 17:21

Ctrl+End also works, in both normal and insert modes. :help <C-End>

share|improve this answer
This only moves the cursor to the last character in the current line. – sebix Oct 6 at 11:15
@sebix: No, check the help. – Kurt Hutchinson Oct 6 at 22:02
Does not work for me with vim 7.4 – sebix Oct 7 at 13:01
@sebix: It works for me just fine, and the help text is pretty clear. Maybe you have some mapping or plugin that is overriding the built-in behavior. – Kurt Hutchinson Oct 7 at 19:56

G goes to the last line and $ goes to the last character of the line, so

share|improve this answer
Gilles, Thanks this is more of what I was looking for. – Nanda Feb 4 '12 at 0:58

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.