He served in Wyoming and Utah (then both part of the Utah Territory) during the Utah War (1857-1858). During this period, Canby crossed paths with Captain Henry Hopkins Sibley (whom he may have known slightly at West Point) when the captain was court martialed and Canby served on the panel of judges. Sibley was acquitted. Subsequently, Canby wrote an endorsement for a teepee-like army tent that Sibley had invented. Both officers were later assigned to New Mexico where Canby coordinated a campaign against the Navaho in 1860, commanding Sibley in a futile attempt to capture and punish Navajos for "depredations" against the livestock of settlers. The campaign ended in frustration, with Canby and Sibley rarely so much as sighting Navajos, and then usually at a considerable distance that seemed impossible to close.
After a period of clerical duty, Canby became "commanding general of the city and harbor of New York" on July 17, 1863. This assignment immediately followed the New York Draft Riots. He remained in that post until November 9, not only restarting the draft, but overseeing a prisoner of war camp in New York Harbor. He then went to work in the office of the Secretary of War, unofficially describing himself in correspondence as an "Assistant Adjutant General." (Looking back on Canby's record, a twentieth century Adjutant General, Edward F. Witsell, described Canby's position as "similar to that of an Assistant to the Secretary of the Army.") In May 1864, Canby was promoted to major general and returned to the West, where he commanded the Military Division of Western Mississippi. He was wounded in the hip and groin by a sharpshooter while aboard the gunboat USS Cricket on the White River, Arkansas, on November 8, 1864. Canby commanded the Union forces assigned to conduct the campaign against Mobile, Alabama in the spring of 1865, culminating in the Battle of Fort Blakely, which led to the fall of Mobile in April 1865. Canby accepted the surrender of the Confederate forces under General Richard Taylor in Citronelle, on May 4, 1865, and those under General E. Kirby Smith west of the Mississippi River on May 26, 1865.
Canby's achievement in New Mexico had largely been in his planning an overall defensive strategy. He and his opponent, Sibley, both had limited resources. Though Canby was a little better supplied, he saw that defending the entire territory from every possible attack would stretch his forces too thinly. Realizing that Sibley had to attack along a river, especially since New Mexico was in the middle of a long drought, Canby made the best use of his forces by only defending against two possible scenarios: an attack along the Rio Grande and an attack by way of the Pecos and Canadian rivers. Moreover, the latter defensive force could easily be shifted to protect Fort Union if the enemy attacked by way of the Rio Grande, which they did. Canby also took initiative in persuading the governors of both New Mexico and Colorado to raise volunteer units to supplement regular Federal troops; the Colorado troops proved helpful at both Valverde and Glorieta (although Manuel Chavez, a colonel with the New Mexico volunteers played a crucial role in the latter engagement). It was Sibley's campaign to win or lose, and in spite of occasional superior soldiering by Confederate troops and junior commanders, Sibley's sluggishness and vacillation in executing an extremely risky plan led to an almost inevitable Confederate collapse.
Canby was generally regarded as a great administrator, but opinion was mixed as to whether or not he was a great warrior. Ulysses S. Grant thought him not aggressive enough. In a telling incident, Grant sent Canby an order to "destroy [the enemy's] railroads, machine-shops, &c." Ten days later, Grant reprimanded him for requesting men and materials to build railroads. "I wrote... urging you to... destroy railroads, machine-shops, &c., not to build them," Grant said pointedly. The story is instructive regarding Canby's character: although he could be a destroyer when he felt he had to be, he clearly preferred the role of builder. Today, he might be considered a "policy wonk" because he was expert in the minutiae of administration. If someone had a question about army regulations or even Constitutional law affecting the military, Canby was the man to see. Grant himself came to appreciate this in peace time, once complaining vigorously when President Andrew Johnson proposed to assign Canby away from the capital where Grant considered him irreplaceable.
It should be noted that Canby was born in Kentucky and that his father had once owned slaves. Some of Canby's cousins fought for the Confederacy, and one of these was taken prisoner of war. The man's father wrote to Canby asking the general to use his influence to parole his son, but Canby declined on the grounds that he felt he was not entitled to use his influence to benefit family members. Later, when Canby was a military governor during Reconstruction, he declined to favor relatives who had become carpetbaggers in his jurisdiction.
General Canby received conflicting orders from Washington as to whether to make peace or war on the Modocs, but war was not working, so the federal government authorized a peace commission and assigned Canby a key position on it. The purpose of the commission was undermined by the fact that there were many lines of communication between the Modocs and whites. At one point, someone in touch with the Modoc leader Captain Jack, alleged that the governor of Oregon intended to hang nine Modocs, apparently without trial, as soon as they surrendered. This caused the Modocs to break off scheduled talks, and infuriated Canby because he believed that his federal authority trumped the governor's and made the threat irrelevant; if they surrendered to him, Canby had no intention of allowing the Modocs to be punished without a trial.
On April 11, 1873, after months of false starts and aborted meetings, Canby went to another parley, unarmed and with some hope of final resolution; however, Judge Elijah Steele of Yreka, California maintained that when he warned Canby that the Modocs were volatile and apt to kill the peace commissioners at the slightest provocation, Canby replied, "I believe you are right, Mr. Steele, and I shall regard your advice, but it would not be very well for the general in command to be afraid to go where the peace commissioners would venture." The talks were held midway between the army encampment and Captain Jack's Stronghold near Tule Lake. Two members of Canby's party brought concealed weapons, but, even more of the Modocs were armed. Frustrated by the negotiations, Captain Jack, along with Ellen's Man, one of his lieutenants, shot Canby twice in the head and cut his throat. He was the first, and only, General killed during the Indian Wars. Other members of Canby's party were killed, including Reverend Eleazar Thomas. Others were wounded. According to Jeff C. Riddle, author of Indian History of the Modoc War (1914), Canby provoked Captain Jack by claiming that he had no authority to withdraw the 1,000 troops he had positioned nearby. (Riddle was the son of Frank Riddle, Canby's interpreter at the talks.)
Following Canby's death, there was a severe backlash against the Modocs. Eastern newspapers called for blood vengeance. (All except for one newspaper in Georgia that headlined the story: "Captain Jack and Warriors Revenge the South By Murdering General Canby, One of Her Greatest Oppressors." In contrast, citizens of Richmond, Virginia, where Canby had actually served as military governor, met on April 18 to express their appreciation of Canby and sorrow at his death.) E.C. Thomas, son of the murdered peace commissioner, demonstrated the extent and limitation of moderation when he accepted the inevitability and even desirability of reprisals against Captain Jack and his men, but reminded people that his father's memory would be dishonored by generalized malice toward Native Americans: "To be sure, peace will come through war, but not by extermination." Eventually, Captain Jack AKA Kintpuash, Boston Charley, Schonchin John and Black Jim were tried for murder and executed on October 3, 1873. The Modocs were sent to reservations.
After services were performed on the West Coast, Canby was returned to Indiana and buried in Crown Hill Cemetery, Indianapolis, Indiana on May 23, 1873. Attending the final funeral service in Indianapolis were at least four Union generals: William Tecumseh Sherman, Philip Sheridan, Lew Wallace, and Irvin McDowell, the last two serving among the pall bearers. A reporter noted that, although the funeral procession was generally reserved, "more than once, expressions of hatred toward the Modoc" marred the silence.
In recognition of his assassination, Canby's Cross was erected in the 1880s in the area that would later become Lava Beds National Monument. The towns of Canby in Clackamas County, Oregon, Canby in Yellow Medicine County, Minnesota, and Canby in Modoc County, California, are named for him. Every year in Canby, Oregon, on July 4th, the town celebrates General Canby Days, including a pancake breakfast, car show, parade and music.