To help in the ongoing search to make the “home” and “end” keys work in Mac OS X like they work in other operating systems, I give you the Firefox version of KeyFixer. (See here and here for background on the problem and info on how to fix this issue in other apps besides Firefox).
While I believe that this software will not harm your system in any way, it is offered to you for FREE with NO GUARANTEE! This patch for Firefox has been tested by several brave beta testers, and as far as I know, it won’t damage Firefox in any way. I would however, recommend making a backup of your Firefox.app before running this patch. KeyFixer will only try to patch versions of Firefox 2.x found in your Applications folder. Also note that you’ll need to re-run the patch each time you update Firefox.
So, what does the patch do? It simply replaces the platformHTMLBindings.xml file buried deep within a .jar archive inside Firefox.app with a new version that contains fixes to make the home and end keys work correctly. Thanks to everyone who tested this and helped by making suggestions and submitting code. Please post your feedback in the comments section.
Download KeyFixer for Firefox – version 0.2
Also try the regular version of KeyFixer for fixing the home and end keys in other Mac OS X applications.


Could you (if you haven’t already) send this on to the Firefox team? I would love to see this as the default behavior in Firefox. Thanks for your persistence on getting this fixed!
Hi, I try to fix the home and end key. It work on TextEdit and some other but it doesn’t work on Eclipse. I was windows user and if it doesn’t work home and end key, its very difficult to coding in eclipse. Please help me to fix for eclipse.
It works beautifully!!! Thank you so much!!! :)
Works very well indeed. Thanks for the fix!
THANK YOU THANK YOU THANK YOU!!!
Wonderful. Using a mac every day is now slightly less distasteful. Could you make one for thunderbird, as well?
Is there some kind of uninstaller for this program? I found a more general solution for the home/end key thing with the utility DoubleCommand (http://doublecommand.sourceforge.net/). This app seems to work perfectly except for…Firefox, which is (i guess) because of this script i installed earlier.
Hay,
There’s no uninstaller, but since it only changes one file inside Firefox.app, “uninstalling” it can be easily accomplished by upgrading to the newest version of Firefox or by simply replacing your Firefox.app with a new copy.
THANK YOU!!!
I downloaded Keyfixer and Keyfixer Firefox but when I write emails in yahoo, the home and end buttons still doesn’t work? What is the problem here? I do have a new version of Firefox.
Thanks for both of the KeyFixer apps. There is one more place I’d much appreciate its operation: in ThunderBird. Is there a way of using the Firefox version to do its job on TB also? Thanks.
Thank you so much. I have been dying since I switched platforms. Shift – End/Home was a huge shortcut for me on my PC. You have saved my life!!!! :)
Thankyou – great work. Have you considered taking this further, by submitting a patch to the Firefox maintainers that adds a checkbox to Preferences, or at least about:config? That would indeed be the cool official way to go.
Great work… this is a constant frustration as a switcher. Could this be rolled into a firefox extension? I have never made one, but it may be worth looking into for anyone with any experience in this.
You should make this available as a Firefox/Thunderbird extension so that it’ll be re-applied after updating those apps.
Thanks a lot. Unfortunately, I came to this site in after experiencing the frustration with Thunderbird, and that’s about the only app not supported :-(
Can you tell us how to do it manually? Nice work btw!
How to do it manually: http://www.starryhope.com/tech/2006/mac-os-x-home-and-end-keys/
Hi there,
Excellent stuff. Just one thing, can you please port it to Firefox 3?
Firefox 3 looks good on Leopard so I’m using it instead of FF 2.
Many Thanks.
Figured it out. Here’s how to patch Firefox 3.
(I’m using 3.0b2 currently…)
1. Close Firefox
2. Browse to Applications > Firefox
3. Right Click > Show Package Contents
4. Browse to Contents > MacOS > Chrome
5. Rename/Remove toolkit.jar and replace it with this (http://qelix.com/work/firefox3/toolkit.jar) updated one.
Thats all. :-)
Hope it helps some.
Thank you so wonderfully much. You’ve just made my life 10 times better!
THANK YOU, THANK YOU, THANK YOU! It’s only my 3rd day on a Mac and this one issue has cut my productivity in half, I swear. It doesn’t seem to work in Mac Mail, but I’m grateful wherever it does work. :)
It’s now working in Apple Mail, but now i’ve switched to Thunderbird. Pleeeease make a patch for Thunderbird. Please?
THANK YOU!!!!!!!!!!! The firefox patch is great! When it upgraded, it left me hopeless. Thanks for saving my life!!!!!!!
Heya Jim. I’m a huge fan of this, great work. It’s one of the essentials that I can’t live without.
I started using Flock recently and realized that I needed the same fix. Since Flock and Firefox are both Mozilla-based browsers, I modded this script just a little to work for Flock as well.
The Flock-modded Keyfixer is on my site for download if anyone would like it.
http://www.decavolt.com/2008/02/modified-keyfixer-for-flock/
Thanks a lot! This has been driving me crazy once I installed Firefox on my new Mac.
Ariel
Hi,
Thanks for the great tool. I’m a developer switched from windows to mac osx.
Does anybody know how to activate the same feature in eclipse?
Again – Thanks a lot
Rainer
I just discovered that Thunderbird uses the exact same platformHTMLBindings.xml (I diffed it) file so I was able to replace it with the version in this package and now Thunderbird behaves right too.
I also added the following handlers so PC-style Ctrl-Home/End and Shift-Ctrl-Home/End works right too (using Command-Home/End)
Cheers
The Fix above for Firefox 3.0b2 doesn’t work for 3.0b5 – address bar disappears. I don’t know enough to fix this in the jar.
I’ve created keyfixer_firefox v0.3 to address some problems people have seen. Here are the highlights:
* Support for both Firefox 2 and 3 (versions on or after May 2008)
* Running the program twice will uninstall the patch. This is useful when performing upgrades (Firefox won’t upgrade if Keyfixer has been applied — you have to remove it first)
* PageUp and PageDown now moves the cursor instead of just moving the screen. This is more consistent with Firefox on Windows.
Wow. I haven’t heard of this firefox plugin til now. Thanks buddy! I still haven’t upgraded to FF3 yet.. gonna wait a bit for that.
Any chance you will update this for Firefox 3??
Jim, thank you so much for taking the time to make this application. If you do decide to update this for Firefox 3, I know there will be a lot of users appreciating your efforts. Thanks again!
Since there’s no update yet for Firefox 3, I guess we’ll just have to do it manually. I’ve uploaded the necessary jar file to make this work on Firefox 3 (I’m using 3.0.1, btw).
1. Download the new “toolkit.jar” file from http://localhostr.com/files/472b85/toolkit.jar. After downloading, quit Firefox.
2. Go to your Applications folder, select Firefox and Ctrl+Click (Right Click) and select “Show Package Contents”
3. Navigate to “Contents/MacOS/chrome” and make a backup of your original toolkit.jar file by adding a “.bak” extension to make it “toolkit.jar.bak”
4. Drop the new “toolkit.jar” file that you downloaded from step 1 and start Firefox.
Hope this helps..
To bad, it didn’t work for me in this version of Mac OS X 10.5.4 and Firefox released version 3.0.1. Would the toolkit.jar may be language dependent, I’m using the Dutch version of Mac OS X and Firefox?
Keeto, et al, if you’re looking for an update, I suspect you’ll have to search for the many forks of this (apparently) public domain package. As one such project, I’ve posted a keyfixer fork on my blog. This version uses the same code as Keyfixer 0.2, but uses a patching technique instead of a file-replacing technique. The patching approach is able to adapt better to small changes in the XML key binding file from the Firefox team, whereas the file replacement approach will ignore these small changes, making it break sometimes with new Firefox versions.
There are also many jar file approaches (i.e., replace toolkit.jar with another jar file). These have even greater fragility with Firefox upgrades because numerous files in the jar file are blindly replaced, possibly causing crashes. My recommendation is to avoid the jar file approach and to use the 0.3 version of keyfixer that you can find on my blog. This version has withstood the last couple updates to both Firefox 2.0 and 3.0 and (as of August 2008) still works. I doubt it will work indefinitely, but it seems to be the best we have right now… :)
Many thanks to Jim Mendenhall for the original version!
Thanks a lot! But what about Ctrl+Left/Right acts as step by words in other applications?..
Thanks a lot!
But what about Ctrl+Left/Right acts as step by words in other applications?..
I’m using Firefox 3.5 beta and I got the script the work. To do so, copy the keyfixer_firefox to your desktop. Right click and browse package contents.
Navigate to Contents > Resources and open up the file ’script’ with text editor. Remove the version checking and it works fine. Here’s the code to use if you don’t want to figure it out yourself ;)
#!/bin/bash
# See if Firefox is already running
FF_RUNNING=$(ps -ax | grep ‘\/firefox-bin\ ‘)
if [ "$FF_RUNNING" != "" ]
then
echo “Please quit Firefox before running this tool.”
exit
else
FF_VERSION=$(/Applications/Firefox.app/Contents/MacOS/firefox -v | grep -o ‘2\.’)
echo “Found Firefox 3, moving on”
# make a backup of toolkit.jar
cp /Applications/Firefox.app/Contents/MacOS/chrome/toolkit.jar /Applications/Firefox.app/Contents/MacOS/chrome/toolkit.jar.backup
# make a copy of toolkit.jar in /tmp
cp /Applications/Firefox.app/Contents/MacOS/chrome/toolkit.jar /tmp/toolkit.jar
# unzip toolkit.jar
cd /tmp/
unzip -oq toolkit.jar
# copy new platformHTMLBindings.xml
cp $1/Contents/Resources/platformHTMLBindings.xml /tmp/content/global/platformHTMLBindings.xml
# re-jar the files
jar cf toolkit.jar content
# copy this new toolkit.jar file back into Firefox
cp /tmp/toolkit.jar /Applications/Firefox.app/Contents/MacOS/chrome/toolkit.jar
# Cleanup
rm -rf /tmp/content
rm /tmp/toolkit.jar
echo “Firefox has been patched, please restart Firefox and try your home/end keys!”
fi
This may have worked for the beta, but I’m attempting to use on FF 3.5 since it was released, and the above script is not working, I get the error message that essentially says firefox was not found in the applications folder.
For those people looking for a 3.5 compatible version of Keyfixer, it has been supplanted by an add-on of the same name. The add-on means that the keybindings don’t need to be patched for every update of Firefox, rather it’s done at run-time by the add-on.
https://addons.mozilla.org/en-US/firefox/addon/9796
There’s also a description of this on a wiki at http://mavaball.net/wiki/index.php/Keyfixer
I am trying to do this with FF 3:
Mozilla/5.0 (Macintosh; U; Intel Mac OS X 10.5; en-US; rv:1.9.1.1) Gecko/20090715 Firefox/3.5.1
and I get this error:
/Volumes/keyfixer_firefox/keyfixer_firefox.app/Contents/Resources/script:
line 14: [: =: unary operator expected
Firefox 2 not found in /Applications directory
Any chance of allowing us the source to fix? Thanks, Ben
Getting errors trying to run the key fixer for firefox. I am in snow leopard with firefox 3.5.5